/* ==========================================
   Custom Fonts (Museo Sans Family Bundle)
   ========================================== */


@font-face {
    font-family: 'Museo Sans';
    src: url('fonts/museosans/museosans-100-webfont.eot');
    src: url('fonts/museosans/museosans-100-webfont.eot?#iefix') format('embedded-opentype'),
         url('fonts/museosans/museosans-100-webfont.woff') format('woff'),
         url('fonts/museosans/museosans-100-webfont.ttf') format('truetype'),
         url('fonts/museosans/museosans-100-webfont.svg#museo_sans100') format('svg');
    font-weight: 100;
    font-style: normal;
}

@font-face {
    font-family: 'Museo Sans';
    src: url('fonts/museosans/museosans-300-webfont.eot');
    src: url('fonts/museosans/museosans-300-webfont.eot?#iefix') format('embedded-opentype'),
         url('fonts/museosans/museosans-300-webfont.woff') format('woff'),
         url('fonts/museosans/museosans-300-webfont.ttf') format('truetype'),
         url('fonts/museosans/museosans-300-webfont.svg#museo_sans300') format('svg');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'Museo Sans';
    src: url('fonts/museosans/museosans_500-webfont.eot');
    src: url('fonts/museosans/museosans_500-webfont.eot?#iefix') format('embedded-opentype'),
         url('fonts/museosans/museosans_500-webfont.woff') format('woff'),
         url('fonts/museosans/museosans_500-webfont.ttf') format('truetype'),
         url('fonts/museosans/museosans_500-webfont.svg#museo_sans500') format('svg');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'Museo Sans';
    src: url('fonts/museosans/museosans_700-webfont.eot');
    src: url('fonts/museosans/museosans_700-webfont.eot?#iefix') format('embedded-opentype'),
         url('fonts/museosans/museosans_700-webfont.woff') format('woff'),
         url('fonts/museosans/museosans_700-webfont.ttf') format('truetype'),
         url('fonts/museosans/museosans_700-webfont.svg#museo_sans700') format('svg');
    font-weight: 700;
    font-style: normal;
}

@font-face {
    font-family: 'Museo Sans';
    src: url('fonts/museosans/museosans_900-webfont.eot');
    src: url('fonts/museosans/museosans_900-webfont.eot?#iefix') format('embedded-opentype'),
         url('fonts/museosans/museosans_900-webfont.woff') format('woff'),
         url('fonts/museosans/museosans_900-webfont.ttf') format('truetype'),
         url('fonts/museosans/museosans_900-webfont.svg#museo_sans900') format('svg');
    font-weight: 900;
    font-style: normal;
}

/* ==========================================
   Modern Reset & Base Styles
   ========================================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Museo Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: #ffffff;
    color: #111111;
    padding-top: 80px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-weight: 300;
}

/* ==========================================
   Fixed Top Navigation Bar Layout
   ========================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 80px;
    background-color: #ffffff;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
}

/* Precision-Aligned Bottom Border Strip */
.navbar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 40px;
    right: 40px;
    height: 1px;
    background-color: #ff671f; /* Changed from #f0f0f0 to Pantone 165 C Orange */
}

/* Header Text Elements Spacing Pads */

.navbar .brand {
    padding: 0 40px;
    display: flex;
    align-items: center;
}

.navbar .main-nav {
    padding: 0 40px;
}

.brand a {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.brand-logo {
    height: 30px;       /* Keeps desktop scaling heights balanced */
    width: auto;        /* Prevents graphic warping layout errors */
    display: block;
    opacity: 1;         /* FULL DISPLAY: Renders your crisp solid gray asset */
    
    /* Smoothly fades the opacity value across 0.3 seconds */
    transition: opacity 0.3s ease-in-out; 
}

/* Premium Rollover: Softens the signature logo to 65% transparency when interactive */
.brand a:hover .brand-logo {
    opacity: 0.65;     
}

/* Desktop Horizontal Menu */
.main-nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

.main-nav a {
    text-decoration: none;
    color: #666666;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.3s ease-in-out; /* Smooth transition matching your footer */
}

/* When a user moves their mouse over any link, it fades to black */
.main-nav a:hover {
    color: #ff671f;
}

/* This rule forces ONLY the active page link to stay Pantone 165 C Orange */
.main-nav a.active {
    color: #ff671f !important;
}

/* Hide Hamburger Menu Icon by Default on Desktop */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    /* margin-right: 40px;  removed: Aligns perfectly right with your grid line rules */
}

.menu-toggle .bar {
    width: 100%;
    height: 2px;
    background-color: #111111;
    transition: all 0.3s ease;
    display: block;
}

/* ==========================================
   Main Grid Content Area (Desktop Global)
   ========================================== */
main {
    padding: 40px;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    flex: 1;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.project-card {
    position: relative;
    background-color: #ffffff;
}

/* New clean layout rule to make the entire card structural link clickable */
.project-link-wrapper {
    text-decoration: none;
    display: block;
    color: inherit; /* Keeps the text charcoal gray (#111111) instead of link blue */
}

.media-container {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #eaeaea;
    overflow: hidden;
    border-radius: 4px;
}

.media-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

/* Updated hover trigger: Triggers scale when the anchor wrapper is hovered */
.project-link-wrapper:hover .media-container img {
    transform: scale(1.03);
}

/* OPTIONAL premium detail: makes your text shift to your signature orange on hover */
.project-link-wrapper:hover .project-info h3 {
    color: #ff671f;
    transition: color 0.3s ease;
}

.project-info {
    padding: 10px 5px;
}

.project-info h3 {
    font-size: 0.85rem;
    font-weight: 700;
    color: #111111;
    margin-bottom: 4px;
}

/* ==========================================
   Project Detail Pages (2-Column Desktop Layout)
   ========================================== */
.project-page-header {
    padding: 0 5px 30px 5px; /* Adds clear breathing room under the main titles */
}

.project-page-header h2 {
    font-size: 2.2rem;
    font-weight: 700;
    color: #111111;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.project-page-header .project-subtitle {
    font-size: 1.05rem;
    font-weight: 500;
    color: #ff671f; /* Styled using your premium Pantone brand orange */
    line-height: 1.5;
}

/* 1. GRID PARENT REMAINS UNCHANGED */
.project-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    align-items: start; /* Text stays locked to the top */
}

/* 2. UPDATED: Target both link wrappers AND direct media containers */
.project-detail-grid .video-project-trigger,
.project-detail-grid > .media-container {
    position: -webkit-sticky; /* Safari engine compatibility safeguard */
    position: sticky;
    bottom: 0;                /* Dynamically anchors whichever item is in the right column flush with the text baseline */
}


/* Restructured text card with padding reset to lock onto the baseline shelf */
.project-text-card {
    padding: 0 5px;
    max-width: 90%; /* Limits the text width to 80% of the screen */
    width: 100%;    /* Ensures it scales down safely on very small screens */
}

.project-body-text p {
    font-size: 0.95rem;
    font-weight: 300;
    line-height: 1.3;
    color: #444444;
    margin-bottom: 10px;
}


/* Remove bottom margin on the absolute last paragraph so alignment calculation stays perfect */
.project-body-text p:last-child {
    margin-bottom: 0;
}

/* ==========================================
   Immersive Cinematic Lightbox Overlay
   ========================================== */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9); /* Dark background theme */
    z-index: 5000; /* Floats over everything on the page */
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease-in-out;
}

/* Activates smooth fade-in look when open button is clicked */
.lightbox-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

.lightbox-content {
    position: relative;
    width: 90%;
    max-width: 1100px; /* Locks video layout grid limits */
}

/* 16:9 Aspect Video Container Anchor */
.video-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #000000;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.video-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Close Window 'X' Button Link */
.lightbox-close {
    position: absolute;
    top: -45px;
    right: 0;
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 2.5rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s ease;
}

.lightbox-close:hover {
    color: #ff671f; /* Fades to your brand Pantone 165 C orange on hover! */
}

/* Mobile responsive alterations for player layout */
@media (max-width: 768px) {
    .lightbox-close {
        top: -40px;
        right: 10px;
        font-size: 2.2rem;
    }
}

/* ==========================================
   Fixed Sticky Footer Layout
   ========================================== */

.site-footer {
    position: relative;
    width: 100%;
    height: 60px;
    background-color: #ffffff;
    display: flex; 
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px; /* FIXED: Adds matching 40px layout gutters to desktop view */
    box-sizing: border-box;
}

/* Precision-Aligned Top Border Strip */
.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 40px;
    right: 40px;
    height: 1px;
    background-color: #ff671f; /* FIXED: Brought back inside the pseudo-element rule cleanly */
}

/* Footer Content Spacing Pads */
.site-footer .copyright,
.site-footer .contact-email {
    padding: 0; /* FIXED: Reset internal double padding since parent container handles alignment gutters */
}

.site-footer p {
    font-size: 0.85rem;
    color: #666666;
}

.site-footer a {
    color: #666666; /* Fades smoothly back to the current dark charcoal text color */
    text-decoration: none;
    /* Smooth CSS Transition: Makes the rollover color shift like a premium effect */
    transition: color 0.3s ease-in-out;
}

.site-footer a:hover {
    color: #ff671f; /* Pantone 165 C Vibrant Orange */
}


/* ==========================================
Mobile & Responsive Adaptations (Below 1110px)
========================================== */

@media (max-width: 1110px) {
	.project-text-card {
    padding: 0 5px;
    max-width: 100%; /* Limits the text width to 80% of the screen */
    width: 100%;    /* Ensures it scales down safely on very small screens */
}
}

/* ==========================================
Mobile & Responsive Adaptations (Below 840px)
========================================== */

@media (max-width: 1000px) {
.navbar {
padding: 0;
left: 0;
right: 0;
border-bottom: none !important; / THIS LINE FIXES IT: Nukes the outer duplicate line completely */
}

/* Fixed Border Overlaps: Set standard inner alignment margins */
.navbar::after {
left: 20px;
right: 20px;
}

.site-footer::before {
left: 20px;
right: 20px;
}

.navbar .brand {
padding: 0 20px;
}

/* Reveal Hamburger Icon */

.menu-toggle {
display: flex;
margin-right: 20px;
}

/* Transform Menu into a Hidden Vertical Dropdown Drawer */

.main-nav {
position: absolute;
top: 80px;
left: 0;
width: 100%;
background-color: #ffffff;
border-bottom: none; /* REMOVED THE LINE HERE: Prevents it bleeding through when closed */
max-height: 0;
overflow: hidden;
transition: max-height 0.3s ease-in-out;
z-index: 2000;
padding: 0;
}
/* JavaScript Toggle Interface Action */

.main-nav.active {
max-height: 350px;
border-bottom: 1px solid #f0f0f0; /* ADDED THE LINE HERE: Only shows at the very bottom when open! */
}

/* Fixed Menu Stacking: Forces vertical flow override */

.main-nav ul {
flex-direction: column;
gap: 0;
padding: 20px;
}

.main-nav li {
width: 100%;
text-align: center;
padding: 12px 0;
}

main {
padding: 20px;
}

.portfolio-grid {
gap: 15px; /* Tightens up the grid lanes on smaller device screens */
}

/* Keep footer split wide across horizontal tablet surfaces */
.site-footer {
padding: 0;
}

.site-footer .copyright,
.site-footer .contact-email {
padding: 0 20px;
}

/* Hamburger Animation to 'X' when open drawer is toggled */

.menu-toggle.open .bar:nth-child(1) {
transform: translateY(8px) rotate(45deg);
}

.menu-toggle.open .bar:nth-child(2) {
opacity: 0;
}

.menu-toggle.open .bar:nth-child(3) {
transform: translateY(-8px) rotate(-45deg);
}

/* ==========================================
Project Detail Mobile Adaptations (Simultaneous Switch)
========================================== */

.project-page-header {
padding: 0 5px 20px 5px;
}

.project-page-header h2 {
font-size: 1.8rem;
}

.project-detail-grid {
grid-template-columns: 1fr; /* Drops down to single column exactly when navigation updates */
gap: 15px;
}

.project-text-card {
        max-width: 70%; /* Limits the text width to 80% of the screen */
        width: 100%;    /* Ensures it scales down safely on very small screens */
        padding-bottom: 15px; 
    }
}

@media (max-width: 720px) {
	.project-text-card {
	        max-width: 80%; /* Limits the text width to 80% of the screen */
	        width: 100%;    /* Ensures it scales down safely on very small screens */
	    }

}
/* Tiny Phone Screens Breakpoint (Below 480px wide) */

@media (max-width: 480px) {

.site-footer {
flex-direction: column;
justify-content: center;
gap: 8px;
height: auto;
padding: 20px 0;
}

.site-footer .copyright,
.site-footer .contact-email {
padding: 0;
}
.project-text-card {
        max-width: 1000%; /* Limits the text width to 80% of the screen */
        width: 100%;    /* Ensures it scales down safely on very small screens */
    }
}

/* ==========================================
   Project Page Video Thumbnail Hover Micro-Interactions
   ========================================== */
.video-project-trigger {
    display: block;
    cursor: pointer;
    overflow: hidden;
    background-color: #000000; /* Create a dark backdrop channel for the brightness shift */
    border-radius: 4px;
}

.video-project-trigger .media-container img {
    transition: transform 0.4s ease, filter 0.4s ease;
}

/* Elegant Animation Response: The thumbnail swells forward and glows slightly when hovered */
.video-project-trigger:hover .media-container img {
    transform: scale(1.03);    /* Gives an immediate, smooth animation sense of depth */
    filter: brightness(1.1);   /* Illuminates the graphic image and your baked-in play button icon! */
}

/* ==========================================
   About Page Custom Portrait Layout
   ========================================== */

/* 1. Neutralize the standard horizontal video aspect-ratio layout */
.project-detail-grid .about-image-container {
    aspect-ratio: auto;       /* Cleans out the 16/9 restriction completely */
    background-color: transparent; /* Removes Gray background layer placeholder */
    max-width: 480px;         /* Keeps the portrait photo elegant and structured */
    margin: 0 auto;           /* Centers image slot smoothly */
}

/* 2. Style portrait image inside picture tag to render perfectly crisp */
.about-image-container picture img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;      /* Safeguards against image cropping bugs */
    border-radius: 4px;       /* Mirrors your global media rounding styles */
}

/* 3. Mobile adjustments when grid stacks vertically at 1000px wide screens */
@media (max-width: 1000px) {
    .project-detail-grid .about-image-container {
        max-width: 100%;      /* Allows image card expansion across full panel width */
        margin-top: 15px;     /* Grants clean breathing separation beneath text card */
    }
}