/* 1. Global Reset & Body */
* {
    box-sizing: border-box; /* Crucial for grid alignment */
}

body {
    margin: 0;
    padding: 0;
    background-color: #0a0a0a; /* Dark 2026 aesthetic */
    color: #ffffff;
    font-family: 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
}

/* 2. Header & Branding */
header {
    padding: 60px 20px;
    text-align: left;
    max-width: 1400px;
    margin: 0 auto;
}

header h1 {
    font-weight: 300;
    font-size: 2.5rem;
    letter-spacing: -0.02em;
    margin: 0;
    text-transform: uppercase;
}

header p {
    font-size: 0.9rem;
    color: #888;
    margin-top: 10px;
}

/* 3. The Editorial Grid */
.editorial-grid {
    display: grid;
    /* This creates a 12-column grid for maximum flexibility */
    grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: 100px; /* Base unit height */
    grid-auto-flow: dense; /* Fills gaps automatically */
    gap:4px;
    padding: 0 20px 60px 20px;
    max-width: 1400px;
    margin: 0 auto;
}

/* 4. Individual Items */
.item {
    position: relative;
    overflow: hidden;
    background: #1a1a1a;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* THE FIX: Ensures images fill the grid space perfectly */
.item img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    display: block;
    filter: grayscale(10%); /* Moody finish */
    transition: transform 0.8s ease, filter 0.8s ease;
}

.item:hover img {
    transform: scale(1.05);
    filter: grayscale(0%);
}

/* 5. Asymmetrical Spanning Logic (Editorial Mix) */
/* i1 - i10 corresponds to your 10 images */

.i1 { grid-column: span 6; grid-row: span 6; } /* Massive Hero */
.i2 { grid-column: span 3; grid-row: span 4; } /* Tall portrait */
.i3 { grid-column: span 3; grid-row: span 3; }
.i4 { grid-column: span 3; grid-row: span 2; }
.i5 { grid-column: span 6; grid-row: span 3; } /* Wide Landscape */
.i6 { grid-column: span 3; grid-row: span 3; }
.i7 { grid-column: span 3; grid-row: span 5; } /* Super Tall */
.i8 { grid-column: span 3; grid-row: span 2; }
.i9 { grid-column: span 6; grid-row: span 3; }
.i10 { grid-column: span 3; grid-row: span 3; }

/* 6. Responsive Behavior */

/* Tablets */
@media (max-width: 1024px) {
    .editorial-grid {
        grid-template-columns: repeat(6, 1fr);
    }
    /* Reset spans to fit 6 columns */
    .i1, .i5, .i9 { grid-column: span 6; }
    .i2, .i3, .i4, .i6, .i7, .i8, .i10 { grid-column: span 3; }
}

/* Mobile Phones */
@media (max-width: 600px) {
    .editorial-grid {
        display: block; /* Stack images on mobile */
    }
    .item {
        margin-bottom: 15px;
        height: 400px; /* Uniform height for mobile scroll */
    }
    header {
        padding: 40px 20px;
    }
}

/* The Floating Dock Container */
.glass-dock {
    position: fixed;
    bottom: 40px; /* Distance from bottom */
    left: 50%;
    transform: translateX(-50%); /* Centers the dock */
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 25px;
    
    /* 2026 Glassmorphism Look */
    background: rgba(25, 25, 25, 0.7); /* Dark translucent */
    backdrop-filter: blur(5px); /* Blurs photos behind it */
    -webkit-backdrop-filter: blur(1px);
    
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px; /* Pill shape */
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    z-index: 9999;
}

/* Individual Links */
.dock-link {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 8px 12px;
    transition: all 0.3s ease;
}

.dock-link:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Small divider for the Contact link */
.dock-divider {
    width: 1px;
    height: 15px;
    background: rgba(255, 255, 255, 0.2);
    margin: 0 5px;
}

/* Mobile: Scale down slightly */
@media (max-width: 600px) {
    .glass-dock {
        bottom: 20px;
        width: 90%;
        justify-content: center;
        gap: 5px;
        padding: 8px 15px;
    }
    .dock-link {
        font-size: 0.65rem;
        padding: 5px 8px;
    }
}

/* 1. The main dark backdrop */
.lightbox {
    display: none; /* Hidden until clicked */
    position: fixed;
    z-index: 10000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.96); /* Very deep dark */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    cursor: zoom-out;
}

/* 2. THE NEW STACK CONTAINER */
.lightbox-content {
    display: flex; /* Turn it into a flex container */
    flex-direction: column; /* Stack vertically (top to bottom) */
    align-items: center; /* Center everything horizontally */
    justify-content: center; /* Center the stack vertically in the viewport */
    width: 100%;
    height: 100%;
    padding: 30px; /* Air around the stack */
}

/* 3. The Image (Must be child of .lightbox-content) */
.lightbox img {
    display: block;
    object-fit: contain; /* Full composition view, no cropping */
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
    animation: zoomIn 0.3s ease-out;

    /* Responsive Sizing */
    max-width: 90%; /* Max width relative to screen */
    max-height: 80vh; /* This leaves 20% of the screen (vertical height) for text/padding */
}

/* 4. The Caption (Must be child of .lightbox-content) */
.lightbox-caption {
    width: auto;
    max-width: 90%;
    text-align: center;
    margin-top: 15px; /* Spacing below the image */
    
    /* 2026 Editorial Styling */
    color: rgba(255, 255, 255, 0.5); /* Dimmed so photo is star */
    font-size: 0.7rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    pointer-events: none; /* User clicks past text to close */
    animation: fadeIn 0.8s ease-out;
}

/* 5. Mobile Adjustment */
@media (max-width: 600px) {
    .lightbox-content { padding: 15px; }
    .lightbox-caption {
        font-size: 0.6rem;
        letter-spacing: 0.1em;
        margin-top: 10px;
    }
}

/* Animations */
@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Ensure the contact page fits perfectly on one screen */
.contact-page {
    height: calc(100vh - 200px); /* Adjusts for header height */
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: repeat(6, 1fr); /* Force rows to stay inside the screen */
    gap: 15px;
    align-content: center; /* Centers the whole grid vertically */
}

.contact-hero {
    grid-column: span 12;
    grid-row: span 3; /* Shorter span to keep it on one screen */
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px;
    background: #050505 !important;
}

.social-block {
    grid-column: span 6;
    grid-row: span 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 30px;
}

/* Hide overflow to prevent accidental scrolling */
body.contact-body {
    overflow: hidden;
}

.huge-link {
    position: relative;
    display: inline-block;
}

.huge-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -5px;
    left: 0;
    background-color: #fff;
    transition: width 0.4s ease;
}

.huge-link:hover::after {
    width: 100%;
}

/* 7. Contact Link Color Fix */
.contact-page a {
    color: #ffffff !important; /* Forces white and overrides browser defaults */
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.contact-page a:visited {
    color: #ffffff !important; /* Prevents purple 'already visited' color */
}

.contact-page a:hover {
    opacity: 0.7; /* Gives a subtle visual cue when hovering */
}

/* Specific size for social links to keep them distinct from the email */
.social-block a {
    font-size: 1.1rem;
    font-weight: 300;
}