/* Clean Black Minimalist Editorial Design System */
:root {
    --bg-color: #08080a;
    --text-primary: #ffffff;
    --text-secondary: #707077;
    --border-color: rgba(255, 255, 255, 0.08);
    
    /* Fonts */
    --font-heading: 'Inter', sans-serif;
    --font-title: 'Arial Black', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --font-body: 'Inter', sans-serif;
    
    /* Transition Speed */
    --timing-slow: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    --timing-fast: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    cursor: none !important; /* Force hide default cursor everywhere */
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    overflow: hidden; /* Disable page scroll completely */
    height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Background Canvas Grid Overlay */
.grid-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1; /* Render behind main page container to avoid visual overlapping */
}

/* Custom cursor overrides - only applied when JS is active */
body.has-custom-cursor * {
    cursor: none !important;
}

/* Custom Cursor: Single White Inverting Dot */
.cursor-dot {
    width: 9.6px;
    height: 9.6px;
    background-color: #ffffff;
    border-radius: 50%;
    position: fixed;
    left: 0;
    top: 0;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    opacity: 0;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

/* Active cursor state on hover: expands to a circle */
body.cursor-hover .cursor-dot {
    transform: translate(-50%, -50%) scale(5.4);
}

/* Hide cursor on touch screens */
@media (hover: none) and (pointer: coarse) {
    .cursor-dot {
        display: none;
    }
    * {
        cursor: auto !important;
    }
}

/* Main Canvas Wrapper */
.canvas {
    width: 100%;
    height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    perspective: 1500px; /* 3D depth perspective for grid flips */
}



/* Info Rows (Top & Bottom Columns) */
.info-row {
    position: absolute;
    left: 0;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    padding: 3rem 4rem;
    z-index: 10;
}

.top-row {
    top: 0;
    padding: 0.6rem 4rem;
}

.bottom-row {
    bottom: 0;
    padding: 3rem 4rem 1.2rem 4rem;
    align-items: flex-end;
}

.info-item {
    display: flex;
    flex-direction: column;
}

/* Symmetrical Alignments for Header Columns */
.top-row .brand {
    align-items: flex-start;
    text-align: left;
    margin-top: 15px; /* Shift text slightly lower */
}

.top-row .header-logo {
    align-items: center;
    text-align: center;
}

.top-row .email {
    align-items: flex-end;
    text-align: right;
    margin-top: 15px; /* Shift text slightly lower */
}

/* Symmetrical Alignments for Footer Columns (Dribbble Removed) */
.bottom-row .info-item:nth-child(1) {
    align-items: flex-start;
    text-align: left;
}

.bottom-row .info-item:nth-child(2) {
    align-items: center;
    text-align: center;
}

.bottom-row .info-item:nth-child(3) {
    align-items: flex-end;
    text-align: right;
}

.mono-label {
    font-family: var(--font-heading);
    font-size: 0.7rem;
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.info-val {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--timing-fast);
}

.status-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    background-color: #ffffff;
    border-radius: 50%;
    margin-right: 8px;
    vertical-align: middle;
    margin-bottom: 2px;
    animation: statusPulse 0.3s infinite ease-in-out;
}

@keyframes statusPulse {
    0%, 100% {
        opacity: 0.35;
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
    }
    50% {
        opacity: 1;
        box-shadow: 0 0 8px 2.5px rgba(255, 255, 255, 0.7);
    }
}

a.info-val:hover {
    color: var(--text-secondary);
}

/* Header Logo Styling */
.header-logo {
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-link {
    display: block;
    transition: var(--timing-fast);
}

.logo-img {
    height: 150px;
    width: auto;
    display: block;
    transition: var(--timing-fast);
}

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

/* Scattered Collage Artwork Images */
.artwork-collage {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    pointer-events: none;
}

.collage-item {
    position: absolute;
    background-color: transparent;
    text-decoration: none;
    border-radius: 5px;
    overflow: hidden;
    pointer-events: auto; /* Active cursor interactions */
    /* Combined transform support without flip rotations */
    transform: translate3d(var(--drag-x, 0px), var(--drag-y, 0px), 0px) 
               scale(var(--scale, 1)) 
               rotate(var(--rotate, 0deg)) 
               translate3d(var(--para-x, 0px), var(--para-y, 0px), 0px);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.8s ease;
    user-select: none; /* Prevent text highlight blocks during drags */
    -webkit-user-drag: none;
    z-index: 2; /* Sits above background watermark */
    backface-visibility: hidden;
}



/* Set 2 Inactive state (Flat & Faded Out) */
.set-2-collage .collage-item {
    opacity: 0;
    pointer-events: none;
    transform: translate3d(var(--drag-x, 0px), var(--drag-y, 0px), 0px) 
               scale(var(--scale, 1)) 
               rotate(var(--rotate, 0deg)) 
               translate3d(var(--para-x, 0px), var(--para-y, 0px), 0px);
    /* Fade out immediately on set switch */
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                opacity 0.2s ease;
    transition-delay: 0s !important;
}

/* Set 2 Active state (Flat & Faded In) */
body.show-set-2 .set-2-collage .collage-item {
    opacity: 1;
    pointer-events: auto;
    transform: translate3d(var(--drag-x, 0px), var(--drag-y, 0px), 0px) 
               scale(var(--scale, 1)) 
               rotate(var(--rotate, 0deg)) 
               translate3d(var(--para-x, 0px), var(--para-y, 0px), 0px);
    /* Transition opacity with delay, but keep transform fast and responsive! */
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                opacity 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: 0s, calc(0.2s + var(--delay, 0s)) !important;
}

.collage-item.dragging {
    transition: none !important; /* Zero lag interactive drags */
    z-index: 1000 !important;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4);
    cursor: grabbing !important;
    /* Reset parallax while dragging to prevent offset drift and jitter */
    --para-x: 0px !important;
    --para-y: 0px !important;
}

.collage-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease;
}

.blank-placeholder {
    width: 100%;
    height: 100%;
    background-color: #ffffff;
    box-shadow: inset 0 0 20px rgba(0,0,0,0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Set Grid Transition Wrappers */
.set-2-collage {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    pointer-events: none;
    transform-style: preserve-3d;
}

.set-1-collage {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    pointer-events: none;
    transform-style: preserve-3d;
}

body.show-set-2 .set-1-collage {
    pointer-events: none;
}

body.show-set-2 .set-2-collage {
    pointer-events: auto;
}

/* Set 1 Scattered Collage Layout Positions (Scaled & shifted to maintain strict margins below header and above footer) */
.pos-set1-1 {
    width: calc(11vw + 25px);
    height: calc((11vw + 25px) + 1.8rem); /* Width + caption offset height */
    top: 26vh;
    left: 12vw;
}
.pos-set1-2 {
    width: calc(12vw + 25px);
    height: calc((12vw + 25px) + 1.8rem);
    top: 22vh;
    left: 74vw;
}
.pos-set1-3 {
    width: calc(16vw + 25px);
    height: calc((16vw + 25px) / 2.6 + 1.8rem); /* 2.6:1 ratio + caption offset */
    top: 61vh;
    left: 8vw;
}
.pos-set1-4 {
    width: calc(10.5vw + 25px);
    height: calc((10.5vw + 25px) * 9 / 8 + 1.8rem); /* 8:9 ratio + caption offset */
    top: 57vh;
    left: 80vw;
}
.pos-set1-5 {
    width: calc(11vw + 25px);
    height: calc((11vw + 25px) * 957 / 1024 + 1.8rem); /* 1024:957 ratio + caption offset */
    top: 40vh;
    left: 29vw;
}
.pos-set1-6 {
    width: calc(8.5vw + 25px);
    height: calc((8.5vw + 25px) * 16 / 9 + 1.8rem); /* 9:16 ratio + caption offset */
    top: 22vh;
    left: 52vw;
}
.pos-set1-7 {
    width: calc(14vw + 25px);
    height: calc((14vw + 25px) * 9 / 16 + 1.8rem); /* 16:9 ratio + caption offset */
    top: 65.5vh;
    left: 48vw;
}

/* Set 1 Collage Items (Flex container for image wrapper + text label) */
.set-1-collage .collage-item {
    display: flex;
    flex-direction: column;
    pointer-events: auto;
    opacity: 1;
    /* Transition opacity with delay, but keep transform fast and responsive! */
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                opacity 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: 0s, calc(0.2s + var(--delay, 0s)) !important;
}

body.show-set-2 .set-1-collage .collage-item {
    opacity: 0;
    pointer-events: none;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                opacity 0.2s ease;
    transition-delay: 0s !important;
}

/* Inner image wrapper isolates cover-fitted image overlays and zooms */
.set-1-collage .collage-item .image-wrapper {
    flex: 1;
    width: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 4px;
}

.set-1-collage .collage-item .image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease;
}

.scatter-caption {
    font-family: var(--font-heading);
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    display: block;
    line-height: 1.35;
    pointer-events: none;
    user-select: none;
}

.caption-top {
    margin-bottom: 0.6rem;
    text-align: center;
}

.caption-bottom {
    margin-top: 0.6rem;
    text-align: center;
}

/* Caption Alignment Overrides */
.align-left {
    text-align: left !important;
}

.align-right {
    text-align: right !important;
}

.set-2-collage {
    pointer-events: none;
}

/* Background Watermark Center Text */
.experimental-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
    text-decoration: none;
    opacity: 0; /* Hidden by default on Set 1 */
    letter-spacing: 0.4em;
    text-transform: uppercase;
    pointer-events: none;
    user-select: none;
    z-index: 5; /* Above background images to make it easily hoverable/clickable */
    text-align: center;
    transition: opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1), 
                color 0.3s ease, 
                text-shadow 0.3s ease;
}

body.show-set-2 .experimental-bg {
    opacity: 0.75; /* Fades in when Set 2 is active */
    pointer-events: auto; /* Clickable on Set 2 only */
}

.experimental-bg:hover {
    color: #ffffff;
    opacity: 1 !important;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
}

/* Set 1 sizes are defined uniformly in the .set-1-collage .collage-item selector above */


/* Set 2 Smaller Scattered Images Layout Positions (17 items in a Staggered 360-degree circular pattern wrapping EXPERIMENTAL) */
.pos-s2-1 {
    width: calc(10.5vw - 15px);
    height: calc(12.3vw - 15px);
    top: 52%;
    left: 74%;
}
.pos-s2-2 {
    width: calc(7.19vw - 15px);
    height: calc(9vw - 15px);
    top: 53.8%;
    left: 66.1%;
}
.pos-s2-3 {
    width: calc(11.5vw - 15px);
    height: calc(6.5vw - 15px);
    top: 73%;
    left: 64.8%;
}
.pos-s2-4 {
    width: calc(11.5vw - 15px);
    height: calc(6.5vw - 15px);
    top: 62.5%;
    left: 53.5%;
}
.pos-s2-5 {
    width: calc(7.19vw - 15px);
    height: calc(9vw - 15px);
    top: 67.5%;
    left: 44.3%;
}
.pos-s2-6 {
    width: calc(5.06vw - 15px);
    height: calc(9vw - 15px);
    top: 60%;
    left: 39.4%;
}
.pos-s2-7 {
    width: calc(11.5vw - 15px);
    height: calc(6.5vw - 15px);
    top: 78.2%;
    left: 27%;
}
.pos-s2-8 {
    width: calc(8vw - 15px);
    height: calc(8vw - 15px);
    top: 56.8%;
    left: 29.2%;
}
.pos-s2-9 {
    width: calc(5.06vw - 15px);
    height: calc(9vw - 15px);
    top: 52.5%;
    left: 18%;
}
.pos-s2-10 {
    width: calc(11.5vw - 15px);
    height: calc(6.5vw - 15px);
    top: 42.5%;
    left: 24.8%;
}
.pos-s2-11 {
    width: calc(11.5vw - 15px);
    height: calc(6.5vw - 15px);
    top: 25%;
    left: 20.5%;
}
.pos-s2-12 {
    width: calc(6.75vw - 15px);
    height: calc(9vw - 15px);
    top: 17.5%;
    left: 33.2%;
}
.pos-s2-13 {
    width: calc(8vw - 15px);
    height: calc(8vw - 15px);
    top: 30.2%;
    left: 40.5%;
}
.pos-s2-14 {
    width: calc(8vw - 15px);
    height: calc(8vw - 15px);
    top: 20.8%;
    left: 47.8%;
}
.pos-s2-15 {
    width: calc(8vw - 15px);
    height: calc(8vw - 15px);
    top: 17%;
    left: 56.8%;
}
.pos-s2-16 {
    width: calc(11.27vw - 15px);
    height: calc(7vw - 15px);
    top: 36.5%;
    left: 58.2%;
}
.pos-s2-17 {
    width: calc(7.19vw - 15px);
    height: calc(9vw - 15px);
    top: 29.2%;
    left: 69.7%;
}

/* Image labels visible on hover */
.image-label {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 1rem;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.8) 100%);
    color: #ffffff;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Interactions */
.collage-item:hover {
    z-index: 15;
}


.collage-item:hover img {
    transform: scale(1.04);
    filter: brightness(0.5); /* 50% darker on hover */
}

.collage-item.wip-item:hover img {
    filter: brightness(0.2) !important; /* 80% darker on hover */
}

.collage-item:hover .image-label {
    opacity: 1;
}

/* Work In Progress Center Overlay */
.wip-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    opacity: 0;
    pointer-events: none;
    z-index: 3;
    transition: opacity 0.4s ease;
}

.collage-item.wip-item:hover .wip-overlay {
    opacity: 1;
}

/* Floating Brand Text Container */
.brand-float {
    position: fixed;
    pointer-events: none;
    z-index: 100;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #000000;
    background-color: #ffffff;
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    opacity: 0;
    transform: translate(15px, 15px) scale(0.9);
    transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
}

.brand-float.active {
    opacity: 1;
    transform: translate(15px, 15px) scale(1);
}

/* Responsive Overrides */
@media (max-width: 1024px) {
    /* Retain boxed grid layout on tablet viewports and scale card sizes slightly if needed */
    .set-1-collage {
        width: 86vw;
        left: 7vw;
        height: 64vh;
        top: 18vh;
    }
}

@media (max-width: 768px) {
    .info-row {
        padding: 1.5rem;
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .info-item {
        align-items: center;
        text-align: center;
    }
    
    body {
        overflow-y: auto; /* Allow scrolling on mobile viewports */
        height: auto;
    }
    
    .canvas {
        height: auto;
        min-height: 100vh;
    }
    
    .artwork-collage {
        position: relative;
        height: auto;
        margin: 2rem 0;
    }

    .set-1-collage {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        height: auto;
        display: flex;
        flex-direction: column;
        gap: 5rem;
        border: none;
        background-color: transparent;
        backdrop-filter: none;
        padding: 6rem 1.5rem;
    }
    
    .set-1-collage .collage-item {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        width: 75vw !important;
        height: auto !important;
        max-width: none !important;
        max-height: none !important;
        margin: 0 auto;
        display: flex;
        flex-direction: column;
    }

    .set-1-collage .collage-item .image-wrapper {
        width: 100%;
        height: auto;
        position: relative;
        overflow: hidden;
        border-radius: 4px;
    }

    .set-1-collage .collage-item .image-wrapper img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    .set-1-collage .scatter-caption {
        width: 100%;
        font-size: 0.65rem;
        text-align: center !important; /* Centered on mobile viewports for clean stack layout */
    }

    /* Maintain actual image aspect ratios inside wrappers on mobile */
    .pos-set1-1 .image-wrapper { aspect-ratio: 1 / 1; }
    .pos-set1-2 .image-wrapper { aspect-ratio: 1 / 1; }
    .pos-set1-3 .image-wrapper { aspect-ratio: 2.6 / 1; }
    .pos-set1-4 .image-wrapper { aspect-ratio: 8 / 9; }
    .pos-set1-5 .image-wrapper { aspect-ratio: 1024 / 957; }
    .pos-set1-6 .image-wrapper { aspect-ratio: 9 / 16; }
    .pos-set1-7 .image-wrapper { aspect-ratio: 16 / 9; }
}

/* Preview Lightbox Modal */
.preview-modal {
    display: none;
    position: fixed;
    z-index: 2000; /* Highest priority */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s ease;
}
.preview-modal.show {
    display: flex;
    opacity: 1;
}
.modal-wrapper {
    position: relative;
    max-width: 80%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.modal-content {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 5px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: scale(0.95);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.preview-modal.show .modal-content {
    transform: scale(1);
}
.close-btn {
    position: absolute;
    top: 30px;
    right: 45px;
    color: #888888;
    font-size: 40px;
    font-weight: 200;
    transition: color 0.3s ease, transform 0.3s ease;
    cursor: pointer;
    z-index: 2101;
}
.close-btn:hover {
    color: #ffffff;
    transform: rotate(90deg);
}
.modal-caption {
    margin-top: 1.5rem;
    text-align: center;
    color: #ffffff;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}
.modal-caption a {
    color: #ffffff;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.4);
    margin-left: 1rem;
    padding-bottom: 2px;
    transition: border-color 0.3s ease;
}
.modal-caption a:hover {
    border-bottom-color: #ffffff;
}

/* ==========================================================================
   Scroll Reminder "What If?" Indicator Styles
   ========================================================================== */
.scroll-reminder {
    position: absolute;
    bottom: 3.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 100;
    pointer-events: none;
    user-select: none;
    opacity: 0.5; /* 50% Opacity */
    transition: opacity 1.5s cubic-bezier(0.22, 1, 0.36, 1), 
                transform 1.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.scroll-reminder.hidden {
    opacity: 0;
    transform: translate(-50%, 15px);
}

.scroll-text {
    font-family: var(--font-heading);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    margin-bottom: 0.8rem;
    opacity: 0.9;
}

.scroll-line {
    width: 1px;
    height: 35px;
    background: linear-gradient(180deg, var(--text-primary) 0%, rgba(255,255,255,0) 100%);
    position: relative;
    overflow: hidden;
}

.scroll-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    animation: scrollLineAnimation 2.4s infinite cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes scrollLineAnimation {
    0% {
        transform: translateY(-100%);
    }
    70%, 100% {
        transform: translateY(100%);
    }
}

