/* styles.css */
@font-face {
    font-family: 'ProximaNova';
    src: url('assets/fonts/ProximaNova-Regular.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'ProximaNova';
    src: url('assets/fonts/ProximaNova-Light.otf') format('opentype');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'ProximaNova';
    src: url('assets/fonts/ProximaNova-SemiBold.otf') format('opentype');
    font-weight: bold;
    font-style: normal;
}

@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@300&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-family: sans-serif;
    -ms-text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'ProximaNova', 'HelveticaNeue-Light', sans-serif;
}

h1 {
    font-size: 50px;
    font-weight: bold;
    font-family: 'ProximaNova', 'HelveticaNeue-Light', sans-serif;
    color: #ffffff;
    margin-bottom: 10px;
}

main,
nav {
    display: block;
}

.landing {
    margin: 0;
    font-family: 'ProximaNova', 'HelveticaNeue-Light', sans-serif;
    font-weight: normal;
    transition: opacity 0.5s ease-out;
}


.header {
    display: block;
}

.header--nav {
    flex: 1;
    text-align: right;
}

.richtext h2,
.header--logo {
    font-size: 28px;
    font-size: 1.55556rem;
    font-weight: normal;
    margin-top: 2em;
    margin-bottom: 1em
}

.richtext h2:first-child,
.header--logo:first-child {
    margin-top: 0
}

.richtext h2:last-child,
.header--logo:last-child {
    margin-bottom: 0
}

.richtext h3 {
    font-size: 18px;
    font-size: 1rem;
    font-weight: normal;
    margin-top: 2em;
    margin-bottom: 1em
}

.richtext h3:first-child {
    margin-top: 0
}

.richtext h3:last-child {
    margin-bottom: 0
}

.richtext h4,
.richtext h5,
.richtext h6 {
    font-weight: normal;
    margin-top: 2em;
    margin-bottom: 1em
}

.richtext h4:first-child,
.richtext h5:first-child,
.richtext h6:first-child {
    margin-top: 0
}

.richtext h4:last-child,
.richtext h5:last-child,
.richtext h6:last-child {
    margin-bottom: 0
}

.header--logo {
    display: block;
    position: fixed;
    left: 70px;
    top: 50px;
    margin: 0;
    padding: 10px;
    z-index: 60;
    transition: -webkit-transform 0.4s cubic-bezier(1, 0, 0, 1);
    transition: transform 0.4s cubic-bezier(1, 0, 0, 1);
    transition: transform 0.4s cubic-bezier(1, 0, 0, 1), -webkit-transform 0.4s cubic-bezier(1, 0, 0, 1);
    text-decoration: none
}

.logo {
    text-decoration: none
}

.logo:before {
    content: 'â† '
}

a {
    color: #000000
}

*:focus {
    outline: none
}

.header--nav {
    display: block;
    position: fixed;
    right: 160px;
    top: 57px;
    margin: 0;
    width: 20px;
    height: 16px;
    padding: 10px;
    z-index: 59;
    transition: opacity 0.2s linear 0.2s
}

.site-content {
    height: 100%;
    opacity: 1;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    -webkit-transform-origin: 0 0;
    -ms-transform-origin: 0 0;
    transform-origin: 0 0;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden
}

.site-content--inner {
    height: 100%
}

.site-content.is-styleguide .article_stage {
    position: relative
}

.site-content.is-inactive {
    opacity: 0
}

.site-content.is-loading:before {
    display: block
}

.site-content--inner {
    height: 100%
}



.l-site_width {
    position: relative;
    margin: 0 auto;
    padding: 40px;
    padding-top: 160px;
    box-sizing: border-box;
    height: 100%;
    justify-content: center;
}



.article_page {
    height: 100%;
    background: #ffffff;
    opacity: 1;
    transition: opacity 0.2s ease-in-out, transform 0.4s cubic-bezier(1, 0, 0, 1);
    transition: transform 0.4s cubic-bezier(1, 0, 0, 1), opacity 0.2s ease-in-out;
    transition: transform 0.4s cubic-bezier(1, 0, 0, 1), opacity 0.2s ease-in-out, -webkit-transform 0.4s cubic-bezier(1, 0, 0, 1)
}


.article_page--inner {
    height: 100%
}

.article_page--target {
    height: 100%;
    background: #ffffff
}



.teaser {
    background: #ffffff;
    word-spacing: -0.55ex
}

.teaser.has-category {
    height: 100%
}

.image-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    padding: 1px;
    margin: 0 auto;
    padding: 0 auto;
    margin-top: -37px;
}

.image-container img {
    width: 100%;
    max-width: 430px;
    height: auto;
}


.image-wrapper {
    position: relative;
    display: inline-block;
    margin: 10px;
    margin-bottom: 6px;
}

.image-wrapper::before {
    position: absolute;
    background-color: rgba(43, 4, 65, 0.07);
    opacity: 1;
    transition: opacity ease 200ms;
}

.image-text {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    overflow: auto;
    display: flex;
    align-content: center;
    justify-content: center;
    flex-direction: column;
    padding: 7%;
    text-align: center;
    z-index: 100;
    transition: opacity ease 200ms;
    color: white;
    font-size: 32px;
    font-weight: bold;
    pointer-events: none;
}

.image-link {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 101;
}

.image-wrapper:hover::before {
    opacity: 0;
}

.image-wrapper:hover .image-text {
    opacity: 0;
}


.thumbs-link {
    color: #888;
    text-decoration: none;
    transition: color 0.2s ease;
    
    /* --- INVISIBLE HIT-BOX TRICK --- */
    display: inline-block;
    padding: 15px 15px;       /* Creates a large invisible box around the text */
    margin: -15px -15px;      /* Pulls it back so the layout doesn't break visually */
    position: relative;
    z-index: 160;             /* Ensures the hit-box stays on top of everything */
}

.thumbs-link:hover {
    color: #000;
}

.separator {
    margin: 0 8px;
}


/* Media query for screens between 1399px and 900px */
/* @media only screen and (max-width: 1399px) and (min-width: 900px) {
    .image-container img {
        width: 100%;
        max-width: 500px;
        height: auto;
        margin: 20px;
        margin-top: 50px;
    }
} */

/* Media query for screens between 899px and 768px */
/* @media only screen and (max-width: 899px) and (min-width: 768px) {
    .image-container img {
        max-width: 500px;
        height: auto;
        margin: 20px;
        margin-top: 50px;
    }
} */

/* Media query for screens 768px to 598px */
@media only screen and (max-width: 768px) and (min-width: 598px) {
    .image-container img {
        max-width: 100%;
        margin: 10px;
    }
}

@media only screen and (max-width: 598px) {

    /* FIXME does not work too small*/
    .image-container img {
        width: 100%;
        /* max-width: 500px; */
        /*FIXME Hot fix */
        height: auto;
        margin: 10px;
    }
}

 .image-container {
    position: relative;
    max-width: 100%;
    overflow: hidden;
    display: flex;
    justify-content: center;
    padding: 30px;
    flex-wrap: wrap;
}
/*
.image-container img {
    width: 100%;
    max-width: 400px;
    height: auto;
    margin: 0 45px;
    margin-bottom: 20px;
} */

/* .image-container a {
    display: inline-block;
    text-decoration: none;
}

.image-container a img {
    width: 100%;
    max-width: 400px;
    height: auto;
    margin: 0;
} */



/* 
@media screen and (max-width: 768px) {
    .header--inner {
        flex-direction: column;
    }

    .header--nav {
        text-align: center;
        margin-top: 10px;
    }

    .nav-links li {
        display: block;
        margin: 10px 0;
    }
} */


.nav-links {
    list-style: none;
    display: flex;
    gap: 20px;
}

.nav-links li {
    margin: 0;
}

.nav-links a {
    text-decoration: none;
    color: grey;
    font-size: 1em;
}

.nav-links a:hover {
    color: black;
}

.nav-links a:active {
    color: black;
    /* active link color is now black */
}


.center_div {
    background-image: url('../assets/thumbs/landing_image.jpg');
    background-size: cover;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}


.landing_button {
    display: inline-block;
    background-color: transparent;
    color: #ffffff;
    padding: 5px 20px;
    margin-top: 20px;
    text-decoration: none;
    border-radius: 5px;
    border: 2px solid #ffffff;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.landing_button:hover {
    background-color: #fdc865;
    color: #000000;
    border-color: #fdc865;
}

.instagram {
    display: inline-block;
    width: 39px;
    height: 39px;
    background-image: url('../assets/thumbs/instagram_icon.png');
    background-size: contain;
    background-color: transparent;
    transition: background-image 0.3s ease;
    margin-top: 19.5px;
    margin-left: 10px;
}

.instagram:hover {
    filter: invert(36%) sepia(66%) saturate(400%) hue-rotate(1deg) brightness(110%) contrast(103%);
}

.landing_container {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.landing_actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}

.landing_container {
    text-align: center;
}

p {
    font-size: 20px;
    color: #888;
}


.grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 94.5%;
    margin: 0 auto;
    padding: 0 auto;
}

.grid-item {
    width: calc(33% - 10px);
    margin: 3px;
    margin-left: 5px;
    margin-right: 5px;
}

.grid-item img {
    width: 100%;
    height: auto;
    max-height: 100vh;
}

@media screen and (max-width: 600px) {
    .grid-item {
        width: calc(100% - 10px);
        margin: 2px;
        box-sizing: border-box;
        will-change: transform;
    }

    /* .grid-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    } */
}

.grid-sizer {
    display: none;
}

.vbox-content,
.vbox-container,
.vbox-overlay,
.vbox-content img {
    margin: 0;
    padding: 0;
    border: none;
    transition: transform 0.3s ease-in-out;
    box-sizing: border-box;
}

/* Ensure images inside VenoBox slideshow are displayed without extra space */
.vbox-content img {
    display: block;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    max-height: 78vh;
}

.venobox {
    outline: none;
}

.venobox-open {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow-y: auto;
}

body:not(.venobox-open) {
    position: static;
    overflow-y: auto;
}

.venobox-open .site-content {
    overflow-y: hidden;
}



/* --- PORTFOLIO GALLERY STYLES --- */
.portfolio-body {
    background-color: #ffffff;
    overflow: hidden; 
    display: flex;
    flex-direction: column;
    height: 100vh;
    margin: 0;
}

@keyframes pageLoad {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

/* Header & footer for gallery controls */
.portfolio-header, .portfolio-footer {
    position: fixed;
    left: 0;
    right: 0;
    padding: 25px 40px;
    display: flex;
    align-items: center;
    z-index: 150;
    background: transparent;
    pointer-events: none; /* Let clicks pass through empty areas */
}

.portfolio-header {
    top: 0;
    justify-content: space-between;
}

.portfolio-footer {
    bottom: 0;
    justify-content: flex-end; /* Aligns the Thumbs button to the right */
}

.portfolio-header a, .portfolio-footer a {
    text-decoration: none;
    font-size: 14px; /* Matches menu size */
    font-weight: 500; /* Matches menu weight */
    color: #000;
    letter-spacing: 0.05em;
    text-transform: capitalize;
    pointer-events: auto;
    display: inline-block;
    padding: 40px;
    margin: -40px;
}

.thumbs-toggle {
    cursor: pointer;
    transition: color 0.2s ease;
    /* padding: 10px;
    margin: -10px; */
}

.thumbs-toggle:hover {
    color: #888;
}

/* Main image stage layout */

/* Dynamic cursor styling */
#cursor-text {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    font-size: 12px;
    letter-spacing: 1.5px;
    font-weight: 600;
    text-transform: uppercase;
    /* transform: translate(-50%, -50%); */
    mix-blend-mode: difference; 
    color: #fff;
    opacity: 0; 
    transition: opacity 0.15s ease;
}

.portfolio-body:hover #cursor-text {
    opacity: 1;
}

/* --- INDEX VIEW STYLES --- */
.is-hidden {
    display: none !important;
    opacity: 0;
}

.index-container {
    position: fixed; 
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    padding: 100px 40px 100px 40px; 
    overflow-y: auto; 
    background-color: rgba(255, 255, 255, 0.90); 
    backdrop-filter: blur(2px); 
    -webkit-backdrop-filter: blur(2px);
    z-index: 100; 
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.index-container.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.index-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    row-gap: 15px; 
    column-gap: 15px; 
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    align-items: center; 
    /* Adds a subtle slide-up effect when opening */
    transform: translateY(20px);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.index-container.is-active .index-grid {
    transform: translateY(0);
}

.index-item {
    cursor: pointer;
    display: flex;
    justify-content: center;
}

.index-item img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    transition: opacity 0.3s ease; 
}

.index-item:hover img {
    opacity: 0.5; 
}


/* --- GLOBAL IMAGE PROTECTION --- */
img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-select: none;
}

/* --- ANIMATED WRAPPER & OVERLAY --- */
.main-wrapper {
    width: 100vw;
    height: 100vh;
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.4); /* Darkens the page */
    z-index: 190; /* Right below the sidebar */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s ease, visibility 0.6s ease;
    pointer-events: none;
}

body.menu-open .menu-overlay {
    opacity: 1;
    visibility: visible;
    pointer-events: auto; 
    cursor: pointer;
}


body.menu-open .gallery-main {
    right: 33.33vw; 
    /* Faster, snappier transition (0.6s) when opening */
    transition: right 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

/* Smoothly slide the header and footer buttons left alongside the photo */
.portfolio-header, .portfolio-footer {
    transition: padding-right 0.6s cubic-bezier(0.77, 0, 0.175, 1);
}

body.menu-open .portfolio-header,
body.menu-open .portfolio-footer {
    padding-right: calc(40px + 33.33vw); 
    /* Faster, snappier transition (0.6s) when opening */
    transition: padding-right 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

/* --- MAIN GALLERY STAGE --- */
/* We remove width: 100vw and rely purely on absolute positioning to allow squeezing */
.gallery-main {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0; 
    z-index: 50; 
    /* The 80px keeps the image away from the header/footer. 
       The 5vw (viewport width) keeps it a safe distance from the screen edge AND the sidebar menu */
    padding: 80px 5vw; 
    box-sizing: border-box; /* Crucial: forces padding to act internally, squeezing the image */
    /* Gentle, longer transition (0.9s) when sliding back to full width */
    transition: right 0.9s cubic-bezier(0.25, 1, 0.35, 1); 
}

body.menu-open .gallery-main {
    right: 33.33vw; /* Gracefully squeezes the container, pushing the image left */
}

/* --- IMAGE SIZING & REVEAL EFFECT --- */
.image-stage {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden; /* Crucial: Keeps the shutter wipe strictly inside this box */
}

.image-stage img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    /* opacity: 0; */
    /* transform: scale(0.96);  */
    /* transition: opacity 0.3s ease, transform 0.3s ease;  */
}

/* This class will be added by JS when the image finishes loading */
/* Applies when the image is FADING IN (slow, premium ease curve) */
.image-stage img.is-loaded {
    opacity: 1;
    transform: scale(1);
    transition: opacity 1.5s cubic-bezier(0.19, 1, 0.22, 1), transform 1.5s cubic-bezier(0.19, 1, 0.22, 1);
}


/* The white block that slides over the image */
.gallery-shutter {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #ffffff; /* Blends seamlessly with the background */
    z-index: 10;
    transform: translateY(100%); /* Start hidden below the image */
    pointer-events: none;
}

/* --- HEADER & FOOTER TYPOGRAPHY & SLIDE --- */
.portfolio-header a, .portfolio-footer a {
    text-decoration: none;
    font-size: 13px;
    color: #000;
    font-weight: normal;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    pointer-events: auto; /* Enable clicking on links */
}

/* Smoothly slide the header and footer buttons left alongside the photo */
.portfolio-header, .portfolio-footer {
    position: fixed;
    left: 0;
    right: 0;
    padding: 25px 40px;
    display: flex;
    align-items: center;
    z-index: 150;
    background: transparent;
    pointer-events: none; 
    /* Gentle, longer transition (0.9s) for text sliding back */
    transition: padding-right 0.9s cubic-bezier(0.25, 1, 0.35, 1);
}

body.menu-open .portfolio-header,
body.menu-open .portfolio-footer {
    padding-right: calc(40px + 33.33vw); 
}


/* --- SIDEBAR MENU STYLES --- */
.sidebar-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 33.33vw; 
    min-width: 300px; 
    height: 100vh;
    background-color: rgba(255, 255, 255, 0.97); 
    backdrop-filter: blur(10px); 
    -webkit-backdrop-filter: blur(10px);
    z-index: 200; 
    transform: translateX(100%);
    /* longer transition (0.9s) when the menu slides off-screen */
    transition: transform 0.9s cubic-bezier(0.25, 1, 0.35, 1); 
    box-shadow: -10px 0 40px rgba(0,0,0,0.03); 
    cursor: auto; 
    pointer-events: auto;
}

.sidebar-menu.is-open {
    transform: translateX(0);
    /* Faster, snappier transition (0.6s) when opening */
    transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

/* Internal spacing and layout */
.sidebar-content {
    padding: 25px 40px;
    display: flex;
    flex-direction: column;
    height: 100%;
    box-sizing: border-box;
}

/* Close button alignment */
.close-menu {
    align-self: flex-end;
    cursor: pointer;
    margin-bottom: 60px;
    padding: 10px;
    margin-right: -10px;
    transition: opacity 0.3s ease;
}

.close-menu:hover {
    opacity: 0.5;
}

/* List styling and typography */
.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 20px; /* Space between links */
}

.sidebar-list a {
    text-decoration: none;
    color: #000;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: capitalize; /* Only first letter capitalized */
    transition: color 0.2s ease;
}

.sidebar-list a:hover {
    color: #888;
}

/* Active link style */
.sidebar-list a.active {
    color: #757575;
    pointer-events: none;
    cursor: default;
}

.sidebar-list a.active::before {
    content: '— ';
}

/* --- STAGGERED MENU LINK ANIMATION --- */
.sidebar-list li {
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.19, 1, 0.22, 1);
}

body.menu-open .sidebar-list li {
    opacity: 1;
    transform: translateX(0);
}

/* Delays for the cascade effect */
body.menu-open .sidebar-list li:nth-child(1) { transition-delay: 0.2s; }
body.menu-open .sidebar-list li:nth-child(2) { transition-delay: 0.3s; }
body.menu-open .sidebar-list li:nth-child(3) { transition-delay: 0.4s; }
body.menu-open .sidebar-list li:nth-child(4) { transition-delay: 0.5s; }



/* --- SIDEBAR FOOTER (CONTACT) --- */
.sidebar-footer {
    margin-top: auto; /* Pushes the block to the very bottom of the menu */
    padding-top: 40px;
}

.sidebar-footer a {
    text-decoration: none;
    color: #000;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: capitalize;
    transition: color 0.2s ease;
}

.sidebar-footer a:hover {
    color: #888;
}