/* Lookbook Page - Built on 02-LANDING-PAGE Foundation */

/* 
==============================================================================
🔒 PROTECTED GRID CODE - DO NOT MODIFY 🔒
==============================================================================

This grid architecture has been carefully engineered to:
1. Break out of the 600px page container without overflow
2. Create a centered, responsive 2-column gallery
3. Scale progressively across all device sizes
4. Maintain proper aspect ratios and spacing

CRITICAL: Modifying this code will break the desktop grid layout.
Only modify copy blocks, not the .lookbook-gallery or .gallery-container rules.

If you need to add/modify content sections, work OUTSIDE this gallery section.
The gallery HTML structure must remain: 
<section class="lookbook-gallery">
  <div class="gallery-container">
    <!-- gallery items here -->
  </div>
</section>

==============================================================================
*/

/* Gallery - Clean contained approach */
.lookbook-gallery {
    /* Break out of page container cleanly */
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    
    /* Center and constrain the grid content */
    display: flex;
    justify-content: center;
    margin-top: 120px;
    margin-bottom: 120px;
}

.gallery-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    max-width: 1400px;
    width: 100%;
    padding: 0 60px;
    box-sizing: border-box;
}

.gallery-item {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Image Container */
.image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
    background-color: #f9f9f9;
    overflow: hidden;
}

/* Lookbook Images - Standardized Lazy Loading */
.image-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* Lazy Loading System - Matches Shop Performance */
.image-container[data-lazy] {
    position: relative;
    overflow: hidden;
}

.loading-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f8f8 0%, #eeeeee 100%);
    color: #555;
    font-family: 'JetBrains Mono', monospace;
    text-align: center;
}

.fallback-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Placeholder Images */
.placeholder-image {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #f8f8f8 0%, #eeeeee 100%);
    color: #555;
    font-family: 'JetBrains Mono', monospace;
    text-align: center;
}

.placeholder-text {
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    margin-bottom: 6px;
    line-height: 1.2;
}

.placeholder-subtitle {
    font-size: 0.75rem;
    font-weight: 300;
    letter-spacing: 0.08em;
    opacity: 0.65;
    line-height: 1.3;
}

/* Image Overlay */
.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.88);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    backdrop-filter: blur(1px);
}

.image-container:hover .image-overlay {
    opacity: 1;
}

.product-link {
    color: var(--color-white);
    text-decoration: none;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 400;
    letter-spacing: 0.12em;
    border: 1px solid rgba(255, 255, 255, 0.8);
    padding: 14px 28px;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
}

.product-link:hover {
    background-color: var(--color-white);
    color: var(--color-black);
    border-color: var(--color-white);
    transform: scale(1.02);
}

/* Item Metadata */
.item-meta {
    padding: 0 8px;
    text-align: center;
}

.item-title {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--color-black);
    margin-bottom: 12px;
    letter-spacing: 0.01em;
    line-height: 1.3;
}

.item-concept {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 8px;
}

.item-signal {
    font-size: 0.8rem;
    line-height: 1.5;
    opacity: 0.65;
    font-style: italic;
    letter-spacing: 0.01em;
}

/* Lookbook-specific styling */
.lookbook-intro {
    text-align: center;
}

.lookbook-intro h1 {
    font-family: 'JetBrains Mono', monospace;
    font-size: 2.5rem;
    font-weight: 300;
    color: var(--color-black);
    margin-bottom: 24px;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

/* 
==============================================================================
🧩 COMPONENT-BASED ARCHITECTURE - FUTURE-PROOF DESIGN 🧩
==============================================================================

Problem Analysis:
- Using generic .block selectors creates unwanted dependencies
- Page-level selectors (.block:first-child) cascade and affect grid
- Need isolated, plug-and-play components

Component Strategy:
1. Wordmark Component - Independent spacing control
2. Navigation Component - Self-contained positioning  
3. Grid Component - Completely isolated (already protected)
4. Content Components - Modular text blocks

==============================================================================
*/

/* Navigation alignment now handled by main.css - no overrides needed */

/* CRITICAL: Ensure consistent wordmark/footer positioning on lookbook page */
.page .wordmark-section {
    margin-bottom: 80px !important;
}

.page .footer-section {
    margin-bottom: 40px !important;
    margin-top: 80px !important;
}

/* 🧩 CONTENT COMPONENTS - Modular and reusable */
.content-section {
    /* Standard content block spacing */
    margin-bottom: 80px;
}

.intro-section {
    /* Special intro component with centered text */
    text-align: center;
    margin-bottom: 80px;
}

/* 
==============================================================================
🔧 COMPONENT USAGE GUIDE - PLUG & PLAY ARCHITECTURE 🔧
==============================================================================

HTML Structure:
<section class="block wordmark-section">     <!-- Wordmark Component -->
<section class="block navigation-section">  <!-- Navigation Component -->
<section class="block intro-section">       <!-- Intro Component -->
<section class="block content-section">     <!-- Content Component -->
<section class="lookbook-gallery">          <!-- Grid Component (Protected) -->

Benefits:
✅ No cascade conflicts - each component is isolated
✅ Easy spacing adjustments - modify only the target component
✅ Reusable across pages - copy component HTML + CSS
✅ Future-proof - add new components without affecting existing ones
✅ Debug-friendly - component issues don't affect other sections

==============================================================================
*/

/* Legacy navigation rules - now handled by component classes above */


/* Footer link styling to match homepage */
.footer a {
    color: var(--color-black);
    text-decoration: none;
    border-bottom: none;
    padding-bottom: 0;
    transition: opacity 0.2s ease;
}

.footer a:hover {
    opacity: 0.7;
}

/* Typography Hierarchy - Complementary Font System */
.lookbook-intro {
    text-align: center;
}

.lookbook-intro p {
    font-family: 'Lekton', sans-serif;
    font-weight: 400;
    font-size: 1rem; /* Consistent base size */
    letter-spacing: 0.01em;
    line-height: 1.6;
    max-width: 400px; /* Creates square-ish proportions */
    margin: 0 auto 16px auto; /* Center and space paragraphs */
}

.lookbook-intro p:last-child {
    margin-bottom: 0;
}

/* Enhanced H2 spacing for proper hierarchy */
.lookbook-intro h2 {
    margin-bottom: 40px; /* More breathing room on desktop */
}

/* Desktop first paragraph spacing */
.lookbook-intro p:first-of-type {
    margin-top: 8px; /* Additional space after H2 */
}

/* Maintain JetBrains Mono for headers and technical elements */
.lookbook-intro h1,
.lookbook-intro h2 {
    font-family: 'JetBrains Mono', monospace;
}

/* Lookbook Closing Section - Typography Consistency */
.lookbook-closing {
    text-align: center;
}

.lookbook-closing p {
    font-family: 'Lekton', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    letter-spacing: 0.01em;
    line-height: 1.6;
    max-width: 400px;
    margin: 0 auto 16px auto;
}

.lookbook-closing p:last-child {
    margin-bottom: 0;
}

/* Mobile Typography Enhancement - CLAUDE.md compliant approach */
@media (max-width: 768px) {
    /* Match homepage mobile typography consistency - EXCLUDE footer */
    .block:not(.footer) p {
        line-height: 1.7;
        margin-bottom: 16px;
        font-size: 0.85rem; /* Match homepage body copy size */
    }
    
    /* Add space between H1 and content */
    /* Reduce mobile header sizes to prevent overwhelm */
    .lookbook-intro h1 {
        font-size: 1.5rem; /* Further reduced to prevent wrapping */
        margin-bottom: 20px;
        line-height: 1.1;
    }
    
    .lookbook-intro h2 {
        font-size: 0.9rem; /* Smaller for better balance */
        margin-bottom: 18px;
        line-height: 1.2;
    }
    
    /* Philosophy block optimization - maintain square concept on mobile */
    .lookbook-intro p {
        letter-spacing: 0.01em;
        margin-bottom: 14px;
        max-width: 320px; /* Smaller square for mobile */
    }
    
    /* Closing section mobile optimization */
    .lookbook-closing p {
        letter-spacing: 0.01em;
        margin-bottom: 14px;
        max-width: 320px; /* Smaller square for mobile */
    }
    
    /* Enhanced mobile H2 spacing */
    .lookbook-intro h2 {
        margin-bottom: 28px;
    }
}

/* Mobile Responsive - Matching homepage exactly */
@media (max-width: 768px) {
    /* CRITICAL: Ensure mobile wordmark/footer positioning matches homepage exactly */
    .page .wordmark-section {
        margin-bottom: 60px !important;
    }
    
    .page .footer-section {
        margin-bottom: 40px !important;
        margin-top: 60px !important;
    }
    
    /* Mobile navigation spacing - reduced to show gallery above fold */
    .navigation {
        margin-bottom: 60px;
    }
    
    
    /* 🔒 PROTECTED: Mobile grid rules - DO NOT MODIFY */
    .lookbook-gallery {
        margin-top: 40px;
        margin-bottom: 100px;
    }
    
    .gallery-container {
        grid-template-columns: 1fr;
        gap: 100px;
        padding: 0 16px;
        max-width: 100%;
    }
    
    .gallery-item {
        gap: 32px;
    }
    
    .placeholder-text {
        font-size: 0.95rem;
    }
    
    .placeholder-subtitle {
        font-size: 0.7rem;
    }
    
    .product-link {
        font-size: 0.8rem;
        padding: 12px 24px;
    }
    
    .item-meta {
        padding: 0 4px;
    }
    
    .item-title {
        font-size: 0.95rem;
        margin-bottom: 10px;
    }
    
    .item-concept {
        font-size: 0.85rem;
        margin-bottom: 6px;
    }
    
    .item-signal {
        font-size: 0.75rem;
    }
}

/* Tablet Responsive */
@media (min-width: 769px) and (max-width: 1024px) {
    /* 🔒 PROTECTED: Tablet grid rules - DO NOT MODIFY */
    .gallery-container {
        gap: 40px;
        max-width: 1200px;
        padding: 0 40px;
    }
    
    .lookbook-gallery {
        margin-top: 100px;
        margin-bottom: 100px;
    }
}

/* Desktop Enhancements */
@media (min-width: 1025px) {
    .lookbook-intro h1 {
        font-size: 2.8rem;
        margin-bottom: 28px;
    }
    
    /* 🔒 PROTECTED: Desktop grid rules - DO NOT MODIFY */
    .lookbook-gallery {
        margin-top: 140px;
        margin-bottom: 140px;
    }
    
    /* Mobile override to prevent phantom black space */
    @media (max-width: 768px) {
        .lookbook-gallery {
            margin-bottom: 60px !important; /* Reduced from 140px to prevent phantom space */
        }
    }
    
    .gallery-container {
        gap: 80px;
        max-width: 1800px;  /* Desktop: 1800px */
        padding: 0 80px;
    }
    
    .item-title {
        font-size: 1.1rem;
        margin-bottom: 14px;
    }
    
    .item-concept {
        font-size: 0.95rem;
        margin-bottom: 10px;
    }
    
    .item-signal {
        font-size: 0.85rem;
    }
}

/* Large Desktop */
@media (min-width: 1440px) {
    /* 🔒 PROTECTED: Large desktop grid rules - DO NOT MODIFY */
    .gallery-container {
        max-width: 2000px;  /* Large Desktop: 2000px */
        gap: 100px;
        padding: 0 120px;
    }
    
    .item-title {
        font-size: 1.2rem;
    }
    
    .item-concept {
        font-size: 1rem;
    }
    
    .item-signal {
        font-size: 0.9rem;
    }
}

/* Ultra-Wide Desktop */
@media (min-width: 1920px) {
    /* 🔒 PROTECTED: Ultra-wide grid rules - DO NOT MODIFY */
    .gallery-container {
        max-width: 2400px;  /* Ultra-Wide: 2400px */
        gap: 140px;
        padding: 0 140px;
    }
}

/* Loading Animations */
.gallery-item {
    opacity: 0;
    animation: fadeIn 0.6s ease forwards;
}

.gallery-item:nth-child(1) { animation-delay: 0.1s; }
.gallery-item:nth-child(2) { animation-delay: 0.2s; }
.gallery-item:nth-child(3) { animation-delay: 0.3s; }
.gallery-item:nth-child(4) { animation-delay: 0.4s; }
.gallery-item:nth-child(5) { animation-delay: 0.5s; }

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

/*
==============================================================================
🖼️ HERO COMPOSITION SECTION - NEW ADDITION 🖼️
==============================================================================
*/

/* Hero Section - Full width composition image */
.lookbook-hero {
    margin-bottom: 80px;
    margin-top: 60px;
    /* Break out to match gallery width */
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    display: flex;
    justify-content: center;
}

.hero-image-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10; /* Match image dimensions for no cropping */
    background-color: #f9f9f9;
    overflow: hidden;
    /* Base values - responsive breakpoints handle scaling */
    max-width: 1200px;
    padding: 0 60px;
    box-sizing: border-box;
}

.hero-image-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain; /* Show full composition instead of cropping */
    object-position: center;
    display: block;
}

/* Hero-specific placeholder styling */
.hero-placeholder {
    background: linear-gradient(135deg, #f8f8f8 0%, #eeeeee 100%);
}

.hero-placeholder .placeholder-text {
    font-size: 1.3rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    margin-bottom: 8px;
}

.hero-placeholder .placeholder-subtitle {
    font-size: 0.8rem;
    font-weight: 300;
    letter-spacing: 0.08em;
    opacity: 0.65;
}

/*
==============================================================================
🔧 PRODUCT IMAGE SIZE ADJUSTMENTS - VISUAL BALANCE 🔧
==============================================================================
*/

/* Reduce product image sizes to balance with hero image */
.gallery-container {
    gap: 50px; /* Reduced from 60px */
    max-width: 1200px; /* Reduced from 1400px for better proportion */
}

.image-container {
    aspect-ratio: 3/4; /* Slightly less square, more portrait */
}

/* Mobile responsiveness for hero */
@media (max-width: 768px) {
    .lookbook-hero {
        margin-bottom: 80px; /* Match spacing between gallery items */
        margin-top: 40px;
    }

    .hero-image-container {
        aspect-ratio: 16/10; /* Match image ratio to prevent any cropping */
        padding: 24px; /* White frame padding for generous spacing */
        margin: 0 16px; /* Match gallery margin exactly */
        max-width: calc(100% - 32px); /* Account for the margin */
        background-color: #ffffff; /* White frame background */
        border: 1px solid #f0f0f0; /* Subtle border for definition */
        overflow: visible; /* Allow scaled image to show beyond container */
    }

    /* Mobile: Scale down to show full composition with proper spacing */
    .hero-image-container img {
        position: relative; /* Remove absolute positioning for transform compatibility */
        transform: scale(0.85); /* Scale down to show full image with white frame */
        transform-origin: center;
        object-fit: contain; /* Show full composition without cropping */
        width: 100%;
        height: 100%;
        display: block;
    }

    .hero-placeholder .placeholder-text {
        font-size: 1.1rem;
    }

    .hero-placeholder .placeholder-subtitle {
        font-size: 0.75rem;
    }

    /* Adjust product grid spacing on mobile */
    .gallery-container {
        gap: 80px; /* Reduced from 100px */
    }
}

/* Tablet adjustments */
@media (min-width: 769px) and (max-width: 1024px) {
    .gallery-container,
    .hero-image-container {
        max-width: 1000px;
        padding: 0 40px;
    }

    .gallery-container {
        gap: 35px;
    }
}

/* Desktop refinements */
@media (min-width: 1025px) {
    .gallery-container,
    .hero-image-container {
        max-width: 1400px;
        padding: 0 80px;
    }

    .gallery-container {
        gap: 60px;
    }

    /* Desktop-only: Reduce hero image padding to show more composition */
    .hero-image-container {
        padding: 20px 80px; /* Add top/bottom padding to reduce cropping */
    }
}

/* Large desktop adjustments */
@media (min-width: 1440px) {
    .gallery-container,
    .hero-image-container {
        max-width: 1600px;
        padding: 0 120px;
    }

    .gallery-container {
        gap: 70px;
    }
}

/* Ultra-wide adjustments */
@media (min-width: 1920px) {
    .gallery-container,
    .hero-image-container {
        max-width: 1800px;
        padding: 0 140px;
    }

    .gallery-container {
        gap: 90px;
    }
}

/* Tight kerning for forward slashes to match logo styling */
.tight-slashes {
    letter-spacing: -0.12em;
}

/* Shop the Collection Overlay - full image coverage */
.shop-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
    backdrop-filter: blur(1px);
    cursor: pointer;
    border-radius: 3px;
}

.shop-overlay:hover,
.shop-overlay.scroll-triggered {
    opacity: 1;
}

.shop-label {
    color: var(--color-white);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.7rem;
    font-weight: 400;
    letter-spacing: 0.08em;
    padding: 10px 20px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
    text-decoration: none;
}

.shop-label:hover {
    background-color: var(--color-white);
    color: var(--color-black);
}