/* ─── FONT ────────────────────────────────────────────────── */
@font-face {
    font-family: 'Violet Sans';
    src: url('/fonts/VioletSans-Regular.woff') format('woff');
}

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

body {
    font-family: 'Violet Sans', monospace;
    color: #515151;
    font-size: 15px;
    background: #515151;
}

::selection {
    background: #AEAEAE;
    color: #BBFF00;
}

/* ─── SPLASH ──────────────────────────────────────────────── */
#splash-screen {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: #1a1a1a;
    overflow: hidden;
    cursor: pointer;
    touch-action: none;
    cursor: url('/public/next-image.svg') 10 0, pointer;

}

.info-coming-soon {
    opacity: 0.3;
    cursor: default;
    font-size: 15px;
}


.info-coming-soon:hover::after {
    content: " available soon";
    font-size: 1em;
}

.splash-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.6s ease;
}

.splash-slide.active {
    opacity: 1;
}

.splash-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.splash-timer-bar {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 3px;
    background: rgba(187, 255, 0, 0.3);
    z-index: 1001;
}

.splash-timer-fill {
    height: 100%;
    width: 0%;
    background: #BBFF00;
    transition: width linear;
}

#splash-screen.dismissing {
    transform: translateY(-100%);
    transition: transform 1s cubic-bezier(0.76, 0, 0.24, 1);
}

.mobile-slide {
    display: none;
}

@media (max-width: 768px) {
    .desktop-slide {
        display: none;
    }

    .mobile-slide {
        display: block;
    }
}

/* ─── HEADER ─────────────────────────────────────────────── */
header {
    background: #BBFF00;
    padding: 4px 16px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 3000;
}

nav {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
}

.nav-center {
    text-align: center;
}

.nav-right {
    display: flex;
    gap: 24px;
    justify-content: flex-end;
}

nav a {
    color: #1a1a1a;
    text-decoration: none;
    font-family: 'Violet Sans', monospace;
    font-size: 15px;
}

nav a:hover {
    text-decoration: underline;
}

/* ─── GLOBAL TOGGLE ──────────────────────────────────────── */
.global-toggle-wrap {
    position: fixed;
    top: calc(var(--header-height, 29px) + 8px);
    left: 16px;
    z-index: 200;
    display: flex;
    align-items: center;
    gap: 10px;
    padding-top: 6px;
}

.global-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    flex-shrink: 0;
}

.global-toggle img {
    width: 21px;
    height: 15px;
    display: block;
}

.current-project-title {
    color: #BBFF00;
    font-family: 'Violet Sans', monospace;
    font-size: 17px;
    line-height: 1;
    white-space: nowrap;
}

.current-project-title.hidden {
    display: none;
}

/* ─── SIDEBAR ─────────────────────────────────────────────── */
.sidebar {
    position: fixed;
    top: var(--header-height, 29px);
    left: 0;
    width: calc(100vw / 5);
    height: calc(100vh - var(--header-height, 29px));
    padding: 50px 26px 16px 16px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
}

.sidebar-index {
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar-meta {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow-y: auto;
    flex: 1;
    padding-bottom: 16px;
    transition: opacity 0.3s ease;
    padding-right: 20px;
    scrollbar-width: thin;
    scrollbar-color: #1a1a1a transparent;
}

.sidebar.visible {
    opacity: 1;
    pointer-events: auto;
}

.sidebar-item {
    display: block;
    color: #AEAEAE;
    opacity: 0.35;
    text-decoration: none;
    font-size: 17px;
    line-height: 1.35;
    cursor: pointer;
    transition: opacity 0.2s;
    padding: 4px 0;
    border-bottom: 1px solid rgba(174, 174, 174, 0.35);
}

.sidebar-meta.transitioning {
    opacity: 0;
}

.sidebar-meta-label {
    color: #BBFF00;
    font-size: 18px;
    margin-bottom: 2px;
}

.sidebar-meta-value {
    color: #AEAEAE;
    font-size: 18px;
    line-height: 1.35;
}

.sidebar-meta-value a {
    color: #AEAEAE;
    text-decoration: none;
}

.sidebar-meta-value a:hover {
    text-decoration: underline;
}

.sidebar-description {
    color: #AEAEAE;
    font-size: 18px;
    line-height: 1.15;
    /* margin-top: 32px; */
    /* padding-top: 16px; */
}


.sidebar-item:hover {
    opacity: 0.7;
}

.sidebar-item.active {
    opacity: 1;
    color: #BBFF00;
}

/* ─── LABELS BAR ──────────────────────────────────────────── */
.labels-bar {
    position: fixed;
    top: var(--header-height, 29px);
    left: calc(100vw / 7);
    right: 0;
    z-index: 200;
    grid-template-columns: 6fr 1fr 1fr 1fr;
    gap: 16px;
    padding: 8px 16px 6px 0;
    background: #515151;
    display: none;
}

.labels-bar.visible {
    display: grid;
}

.labels-bar span {
    color: #BBFF00;
    font-size: 17px;
    min-width: 0;
    overflow: hidden;
}

/* ─── STAGE & ENTRIES ────────────────────────────────────── */
.projects-stage {
    position: fixed;
    top: var(--header-height, 29px);
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    transition: left 0.2s cubic-bezier(0.76, 0, 0.24, 1), top 0.4s cubic-bezier(0.76, 0, 0.24, 1);
}

.projects-stage.ui-visible {
    left: calc(100vw / 5);
    top: calc(var(--header-height, 29px) + var(29px));
}

.project-entry {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    transform: translateY(100vh);
    color: #AEAEAE;
}

.project-inner {
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 10px;
    scrollbar-width: thin;
    scrollbar-color: #1a1a1a transparent;
}

.project-inner::-webkit-scrollbar {
    width: 6px;
}

.project-inner::-webkit-scrollbar-track {
    background: transparent;
}

.project-inner::-webkit-scrollbar-thumb {
    background: #1a1a1a;
}

/* ─── PROJECT TEXT ────────────────────────────────────────── */
.project-text {
    position: absolute;
    visibility: hidden;
    pointer-events: none;
    height: 0;
    overflow: hidden;
}

.project-text.visible {
    display: grid;
}

.project-description {
    font-size: 15px;
    line-height: 1.35;
    color: #AEAEAE;
    padding-right: 32px;
    white-space: pre-wrap;

}

.project-year,
.project-types,
.project-links {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    overflow: hidden;
    font-size: 15px;
}

.project-links a {
    color: #AEAEAE;
    text-decoration: none;
}

.project-links a:hover {
    text-decoration: underline;
}

/* ─── MEDIA ───────────────────────────────────────────────── */
.project-entry-media {
    display: grid;
    gap: 0;
}

.project-entry-media.split {
    grid-template-columns: 1fr 1fr;
}

.project-entry-media.single {
    grid-template-columns: 1fr;
}

.project-entry-media.grid {
    grid-template-columns: 1fr 1fr;
}

.media-slot {
    display: flex;
    flex-direction: column;
}

.media-item {
    position: relative;
    overflow: hidden;
    background: #111;
    cursor: url('/public/next-image.svg') 10 0, pointer;
}

.media-item img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    user-select: none;
    -webkit-user-select: none;
}

.media-item iframe {
    width: 100%;
    aspect-ratio: 16/9;
    border: none;
    display: block;
}

.media-click-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    cursor: url('/public/next-image.svg') 0 0, pointer;
}

.media-expand {
    position: absolute;
    top: 8px;
    right: 10px;
    cursor: pointer;
    opacity: 1;
    line-height: 1;
    z-index: 2;
    user-select: none;
    -webkit-user-select: none;
}

.media-expand img {
    width: 18px;
    height: 18px;
    display: block;
    filter: brightness(0) saturate(100%) invert(73%) sepia(0%) saturate(0%) hue-rotate(0deg) brightness(95%);
    mix-blend-mode: difference;
    transition: filter 0.2s;
}

.media-expand:hover img {
    filter: brightness(0) saturate(100%) invert(89%) sepia(97%) saturate(800%) hue-rotate(30deg) brightness(110%);
}

.media-footer {
    padding: 6px 0 0 6px;
    display: flex;
    justify-content: flex-start;
    gap: 5px;
    align-items: center;
}

.media-counter,
.media-caption {
    font-size: 15px;
    color: #AEAEAE;
    font-family: 'Violet Sans', monospace;
}

/* ─── OVERLAY ─────────────────────────────────────────────── */
/* ─── OVERLAY ─────────────────────────────────────────────── */
.overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: #515151;
    z-index: 999;
    flex-direction: column;
}

.overlay.active {
    display: flex;
}

.overlay-close {
    position: absolute;
    top: 16px;
    left: 24px;
    color: #BBFF00;
    font-size: 35px;
    cursor: pointer;
    font-family: 'Violet Sans', monospace;
    z-index: 1001;
}

.overlay-close:hover {

    color: #515151;

}

/* Horizontal strip */
.overlay-viewport {
    flex: 1;
    overflow-x: scroll;
    overflow-y: hidden;
    display: flex;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    /* no scroll-snap-type */
}


.overlay-viewport::-webkit-scrollbar {
    display: none;
}

.overlay-strip {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 0;
}


.overlay-slide {
    flex-shrink: 0;
    height: 100vh;
    width: auto;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    /* no scroll-snap-align */
}

.overlay-slide img {
    height: 100vh;
    max-height: 100vh;
    width: auto;
    max-width: none;
    /* don't constrain width — let it bleed right */
    object-fit: contain;
    display: block;
    user-select: none;
    -webkit-user-select: none;
    cursor: url('/public/next-image.svg') 16 16, pointer;
}

/* Dots */
.overlay-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 1001;
}

.overlay-dot {
    width: 10px;
    height: 10px;
    background: rgba(174, 174, 174, 0.4);
    cursor: pointer;
    transition: background 0.2s;
}

.overlay-dot.active {
    background: #BBFF00;
}

/* ─── SCROLLBAR ───────────────────────────────────────────── */
::-webkit-scrollbar {
    width: 3px;
    height: 3px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #1a1a1a;
    border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
    background: #000;
}

::-webkit-scrollbar-button {
    display: none;
}

* {
    scrollbar-width: thin;
    scrollbar-color: #1a1a1a transparent;
}

.hidden {
    display: none;
}

/* ─── INFO PAGE ───────────────────────────────────────────── */
.info-page {
    display: grid;
    grid-template-columns: 2fr 1fr 2fr 1fr;
    gap: 16px;
    padding: 16px;
    padding-top: calc(var(--header-height, 29px) + 16px);
    min-height: 100vh;
    background-color: #BBB1AE;
}

.info-left {
    padding-top: 8px;
}

.info-bio {
    font-size: 38px;
    line-height: 1.1;
    color: black;
}

.info-right {
    padding-top: 8px;
    /* display: grid; */
    grid-template-columns: 80px 1fr;
    gap: 0 24px;
    align-content: start;
    align-items: baseline;
}



.info-section {
    display: contents;
}

.info-label {
    font-size: 16px;
    color: #BBFF00;
    padding-top: 2px;
    line-height: 1.1;
}

.info-contact {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 16px;
    line-height: 1.35;
    margin-bottom: 60px;
    padding-top: 10px;

}

.info-impressum {

    margin-bottom: 0px;
}

.info-contact a,
.info-contact span {
    color: black;
    text-decoration: none;
}

.info-contact a:hover {
    text-decoration: underline;
}

.info-recognition {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 60px;
    padding-top: 10px;

}

.recognition-group {
    display: flex;
    flex-direction: column;
}

.recognition-year {
    color: #515151;
    font-size: 16px;
    margin-bottom: 2px;
}

.recognition-item {
    display: block;
    color: black;
    text-decoration: none;
    font-size: 16px;
    line-height: 1.35;
    text-decoration: underline;
}

.recognition-item:hover {
    text-decoration: underline;
}

/* ─── FOOTER ──────────────────────────────────────────────── */
footer {
    padding: 16px;
    font-size: 15px;
    color: blue;
    text-align: right;
    background-color: #BBB1AE;
}

/* ─── CUSTOM SELECT (desktop fallback) ───────────────────── */
.mobile-project-selector {
    display: none;
}

.mobile-meta {
    display: none;
}

.read-more-btn {
    display: none;
}

.custom-select {
    position: relative;
    flex: 1;
}

.page-dimmed::after {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 97;
}

body.overlay-open {
    overflow: hidden;
}

/* ─── SIDEBAR LABEL INLINE ───────────────────────────────── */
.sidebar-label-inline {
    color: #BBFF00;
    font-family: 'Violet Sans', monospace;
    font-size: 17px;
    line-height: 1;
    white-space: nowrap;
}

.sidebar-label-inline.hidden {
    display: none;
}

.mobile-meta-bar {
    display: none;
}

/* ─── MOBILE ──────────────────────────────────────────────── */
@media (max-width: 768px) {

    body {
        font-size: 18px;
        overscroll-behavior: none;
    }

    .global-toggle-wrap {
        display: none;
    }

    .sidebar {
        display: none !important;
    }

    .labels-bar {
        display: none !important;
    }

    /* Stage: normal scroll flow */
    .projects-stage {
        position: static;
        overflow: visible;
        /* offset = header + title row + meta bar */
        padding-top: calc(var(--header-height, 29px) + var(--mobile-title-height, 50px) + var(--mobile-meta-height, 36px));
    }

    .project-entry {
        position: static !important;
        height: auto !important;
        transform: none !important;
        transition: none !important;
        overflow: visible;
        display: none;
        color: #AEAEAE;
    }

    .project-entry.mobile-active {
        display: block;
    }

    .project-inner {
        height: auto;
        overflow: visible;
        padding-bottom: 60px;
        display: flex;
        flex-direction: column;
    }

    /* ── TITLE BAR — fixed, only title row has bg ── */
    .mobile-project-selector {
        display: flex !important;
        position: fixed;
        top: var(--header-height, 29px);
        left: 0;
        right: 0;
        z-index: 500;
        flex-direction: column;
        background: transparent;
    }

    .media-expand {

        top: 80000px;

    }

    /* remove dark bg when closed */
    .mobile-project-dropdown {
        background: transparent;
        /* was rgba(0,0,0,0.88) */
    }

    /* dark bg only when open */
    .mobile-project-selector.open .mobile-project-dropdown {
        background: rgba(0, 0, 0, 0.88);
    }

    /* hide all options when closed */
    .mobile-project-dropdown .mobile-dropdown-option {
        display: none;
    }

    /* show only active when closed */
    .mobile-project-dropdown .mobile-dropdown-option.active {
        display: block;
    }

    /* show all when open */
    .mobile-project-selector.open .mobile-project-dropdown .mobile-dropdown-option {
        display: block;
    }

    .mobile-title-row {
        display: flex;
        align-items: baseline;
        justify-content: space-between;
        padding: 10px 8px 8px;
        cursor: pointer;
        background: #515151;
    }

    .mobile-current-title {
        color: #BBFF00;
        font-family: 'Violet Sans', monospace;
        font-size: 28px;
        line-height: 1.1;
        flex: 1;
        z-index: 900;
        padding-top: 2px;
        visibility: hidden;
    }

    .mobile-title-arrow {
        color: #BBFF00;
        font-size: 38px;
        margin-left: 12px;
        margin-right: 12px;

        transition: transform 0.2s;
        font-family: 'Violet Sans', monospace;
        z-index: 900;

    }

    .mobile-project-selector.open .mobile-title-arrow {
        transform: rotate(180deg);
    }

    /* Meta bar — fixed below title row, no bg */
    .mobile-meta-bar {
        display: flex;
        position: relative;
        top: calc(var(--header-height, 29px) + var(--mobile-title-height, 50px));
        left: 0;
        right: 0;
        z-index: 498;
        gap: 16px;
        padding: 6px 8px 8px;
        background: transparent;
        align-items: flex-start;
    }

    .mobile-meta-bar-label {
        display: none;
    }

    .mobile-meta-bar-value {
        color: #BBFF00;
        font-size: 14px;
        font-family: 'Violet Sans', monospace;
        line-height: 1.3;
    }

    .mobile-meta-bar-value a {
        color: #BBFF00;
        text-decoration: none;
    }

    /* Hide meta bar when dropdown is open (body gets class) */
    body.mobile-dropdown-open .mobile-meta-bar {
        visibility: hidden;
    }



    /* Dropdown — starts below title row, covers rest of screen */
    .mobile-project-dropdown {
        /* display: none; */
        position: fixed;
        top: var(--header-height, 29px);
        left: 0;
        right: 0;
        bottom: 0;
        /* background: rgba(0, 0, 0, 0.88); */
        z-index: 499;
        overflow-y: auto;
        /* padding-top: calc(var(--mobile-title-height, 50px) + 12px); */
        padding-left: 8px;
        padding-right: 45px;
        padding-bottom: 8px;
    }

    .mobile-project-selector.open .mobile-project-dropdown {
        display: block;
    }

    .mobile-dropdown-option {
        display: block;
        color: #AEAEAE;
        font-family: 'Violet Sans', monospace;
        font-size: 28px;
        line-height: 1.2;
        cursor: pointer;
        opacity: 0.45;
        text-decoration: none;
        padding-top: 10px;
    }

    .mobile-dropdown-option.active {
        color: #BBFF00;
        opacity: 1;
    }

    .mobile-project-selector.open .mobile-title-row {
        background: transparent;
    }







    .mobile-dropdown-option:hover {
        opacity: 0.8;
    }

    /* Images FIRST */
    .project-entry-media {
        order: 1;
        margin: 0;
        padding: 0;
        gap: 0;
    }

    .project-entry-media.split,
    .project-entry-media.grid {
        grid-template-columns: 1fr;
    }

    .media-item img {
        width: 100%;
        height: auto;
        display: block;
    }

    .media-footer {
        padding: 6px 8px 6px;
    }

    /* Description AFTER images */
    .project-text {
        order: 2;
        display: block !important;
        visibility: visible !important;
        position: static !important;
        height: auto !important;
        padding: 20px 8px 0;
    }

    .project-description {
        font-size: 16px;
        line-height: 1.4;
        color: #AEAEAE;
        padding: 0;
    }

    /* Hide unused elements */
    .project-year,
    .project-types,
    .project-links,
    .mobile-meta,
    .read-more-btn {
        display: none !important;
    }

    /* Nav */
    nav {
        grid-template-columns: auto 1fr;
    }

    .nav-center {
        text-align: left;
        order: -1;
    }

    .nav-right {
        justify-content: flex-end;
        gap: 12px;
    }

    .nav-left {
        display: none;
    }

    /* Info page */
    .info-page {
        display: flex;
        flex-direction: column;
        padding: 4px;
        padding-top: calc(var(--header-height, 29px) + 16px);
        min-height: unset;
        gap: 0;
    }

    .info-left {
        order: 1;
    }

    .info-right {
        order: 2;
        grid-template-columns: 80px 1fr;
        margin-top: 32px;
    }

    .info-page>div:empty {
        display: none;
    }

    .info-bio {
        font-size: 16px;
    }

    #card-canvas-wrapper {
        width: 100% !important;
        height: 240px !important;
        margin-top: 16px !important;
    }

    .info-contact {
        margin-bottom: 48px;
        line-height: 1.15;
    }

    .info-recognition {
        margin-bottom: 48px;
    }

    footer {
        background-color: #BBB1AE;
    }

    #mobile-meta-type {
        display: flex;
        flex-direction: column;
    }


    .media-item {
        cursor: default;
    }

    .media-click-overlay {
        display: none !important;
    }

    .media-counter {
        display: none;

    }

    .media-caption {
        display: none;

    }

    .media-footer {
        display: none;

    }

    .project-description {
        white-space: pre-wrap;
    }

}