        :root {
            --font-main: "Helvetica Neue", Helvetica, Arial, sans-serif;
            --text-primary: #fff;
            --text-secondary: #d4d4d4;
            --text-muted: #aaa;
            --content-max-width: 1360px;
            --content-gutter: clamp(20px, 4vw, 72px);
        }

        *, *::before, *::after {
            box-sizing: border-box;
        }

        body {
            margin: 0;
            padding: 0;
            background: #000;
            color: var(--text-primary);
            font-family: var(--font-main);
            text-align: center;
            min-height: 100vh;
            overflow-x: hidden;
        }

        button,
        input,
        textarea,
        select {
            font-family: inherit;
        }

        header {
            padding: 40px 20px 20px;
            border-bottom: 1px solid #444;
            position: static;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 12px;
        }

        @media (min-width: 821px) {
            header {
                position: sticky;
                top: 0;
                z-index: 1000;
                background: #000;
            }
        }

        nav a {
            color: #fff;
            text-decoration: none;
            margin: 0 18px;
            font-size: 18px;
            font-weight: 300;
            letter-spacing: 1px;
            transition: .3s;
            border-bottom: 1px solid transparent;
            cursor: pointer;
            padding: 6px 4px;
            display: inline-block;
        }

        nav a:hover {
            color: #bbb;
            border-bottom: 1px solid #eee;
        }

        nav a.nav-active {
            color: #fff;
            border-bottom: 1px solid #fff;
        }

        .section {
            display: none;
            width: min(var(--content-max-width), calc(100% - (2 * var(--content-gutter))));
            margin: 0 auto;
            padding: 40px 0;
            animation: fadeIn .6s;
        }

        .active {
            display: block;
        }

        .gallery {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
            gap: 25px;
            margin-top: 30px;
        }

        .gallery img {
            width: 100%;
            height: auto;
            display: block;
            object-fit: contain;
            cursor: pointer;
            transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
            border-radius: 2px;
            filter: grayscale(100%) contrast(1.1);
            position: relative;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
            animation: fadeInUp 0.8s ease-out forwards;
            opacity: 0;
        }

        .gallery img:nth-child(1) {
            animation-delay: 0.1s;
        }

        .gallery img:nth-child(2) {
            animation-delay: 0.2s;
        }

        .gallery img:nth-child(3) {
            animation-delay: 0.3s;
        }

        .gallery img:nth-child(4) {
            animation-delay: 0.4s;
        }

        .gallery img:nth-child(5) {
            animation-delay: 0.5s;
        }

        .gallery img:nth-child(6) {
            animation-delay: 0.6s;
        }

        .gallery img:hover {
            transform: scale(1.05) translateY(-10px);
            filter: grayscale(0%) contrast(1.2);
            box-shadow: 0 12px 40px rgba(255, 255, 255, 0.15);
            z-index: 10;
        }

        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        h1 {
            font-size: 42px;
            letter-spacing: 4px;
            font-weight: 300;
            margin: 0 0 12px;
        }

        .title-years {
            font-size: 16px;
            letter-spacing: 3px;
            color: var(--text-secondary);
            margin: -2px 0 8px;
        }

        h2 {
            font-size: 28px;
            font-weight: 300;
            margin-bottom: 20px;
        }

        p {
            max-width: 800px;
            margin: auto;
            line-height: 1.7;
            font-size: 18px;
            color: var(--text-secondary);
        }

        .global-contact {
            width: 100%;
            max-width: 100%;
            margin: 56px 0 0;
            padding: 22px 20px 26px;
            box-sizing: border-box;
            font-size: 14px;
            line-height: 1.6;
            color: var(--text-muted);
            opacity: 0.86;
            text-align: center;
            display: flex;
            flex-wrap: wrap;
            justify-content: center;
            align-items: center;
            gap: 0.35em 0.4em;
            border-top: 1px solid rgba(255, 255, 255, 0.12);
            background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0));
        }

        .global-contact a {
            color: var(--text-primary);
            text-decoration: underline;
            text-underline-offset: 3px;
            overflow-wrap: anywhere;
            word-break: break-word;
            display: inline-block;
            max-width: 100%;
        }

        .global-contact a:hover {
            color: var(--text-secondary);
        }

        @keyframes fadeIn {
            from {
                opacity: 0;
            }

            to {
                opacity: 1;
            }
        }

        /* Gallery Tabs */
        .gallery-tabs {
            display: flex;
            justify-content: center;
            gap: 20px;
            margin: 50px 0 60px 0;
        }

        .tab-btn {
            background: transparent;
            color: #888;
            border: none;
            border-bottom: 2px solid transparent;
            padding: 12px 30px;
            font-size: 20px;
            font-weight: 300;
            letter-spacing: 6px;
            cursor: pointer;
            transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
            text-transform: uppercase;
        }

        .tab-btn:hover {
            color: #ccc;
        }

        .tab-btn.active {
            color: #fff;
            border-bottom-color: #fff;
        }

        /* Photo categories */
        .photo-category {
            display: none;
            animation: fadeInCategory 0.6s ease-out;
        }

        .photo-category.active {
            display: block;
        }

        @keyframes fadeInCategory {
            from {
                opacity: 0;
                transform: translateY(20px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* Photo subsections */
        .photo-subsection {
            margin: 40px 0;
            position: relative;
        }

        .photo-subsection h3 {
            font-size: 26px;
            font-weight: 200;
            margin-bottom: 25px;
            color: #ddd;
            letter-spacing: 5px;
            text-transform: uppercase;
            position: relative;
            display: flex;
            flex-direction: column;
            align-items: center;
            padding-bottom: 8px;
        }

        .photo-subsection h3::after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 50px;
            height: 1px;
            background: linear-gradient(90deg, #ddd, transparent);
        }

        .photo-subsection h3 .year {
            font-size: 14px;
            font-weight: 300;
            color: #888;
            letter-spacing: 2px;
            margin-top: 5px;
            display: block;
        }

        .memories-container {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
            gap: 22px;
            margin-top: 30px;
            padding: 0;
            align-items: stretch;
            text-align: left;
        }

        .memory-card {
            position: relative;
            border: 1px solid rgba(255, 255, 255, 0.08);
            background: rgba(255, 255, 255, 0.04);
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
            border-radius: 24px;
            padding: 26px 24px;
            overflow: hidden;
            min-height: 220px;
            max-height: 380px;
            display: flex;
            flex-direction: column;
            justify-content: flex-start;
            backdrop-filter: blur(12px);
            transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
            cursor: pointer;
            text-align: left;
        }

        .memory-card .memory-content {
            overflow-y: auto;
            padding-right: 8px;
            flex: 1;
            min-height: 0;
            display: block;
        }

        .memory-card .memory-content::after {
            content: '';
            display: block;
            clear: both;
        }

        .memory-card .memory-content::-webkit-scrollbar {
            width: 7px;
        }

        .memory-card .memory-content::-webkit-scrollbar-thumb {
            background: rgba(255, 255, 255, 0.18);
            border-radius: 999px;
        }

        .memory-card .memory-content::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.02);
        }

        .memory-card-media {
            float: right;
            width: min(45%, 180px);
            margin: 0 0 10px 14px;
            border-radius: 0;
            overflow: visible;
            border: none;
            background: transparent;
            flex-shrink: 0;
        }

        .memory-card-media img {
            width: 100%;
            height: auto;
            max-height: 160px;
            object-fit: contain;
            display: block;
        }

        .memory-card-image-full .memory-content {
            padding-right: 0;
            overflow: hidden;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .memory-card-image-full .memory-card-media {
            float: none;
            width: 100%;
            margin: 0;
        }

        .memory-card-image-full .memory-card-media img {
            max-height: 220px;
            margin: 0 auto;
        }

        .memory-card::before {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), transparent 40%);
            filter: blur(18px);
            opacity: 0.7;
            pointer-events: none;
            border-radius: inherit;
        }

        .memory-modal {
            position: fixed;
            inset: 0;
            z-index: 10002;
            display: none;
            justify-content: center;
            align-items: center;
            padding: 20px;
            background: rgba(0, 0, 0, 0.88);
        }

        .memory-modal.active {
            display: flex;
        }

        .memory-modal-panel {
            width: min(860px, 100%);
            max-height: min(90vh, 820px);
            overflow: hidden;
            border-radius: 30px;
            background: rgba(10, 10, 10, 0.98);
            border: 1px solid rgba(255, 255, 255, 0.08);
            box-shadow: 0 30px 120px rgba(0, 0, 0, 0.6);
            position: relative;
            padding: 32px 32px 24px;
            display: flex;
            flex-direction: column;
            text-align: left;
        }

        .memory-modal-close {
            position: absolute;
            top: 18px;
            right: 18px;
            width: 42px;
            height: 42px;
            border-radius: 50%;
            border: 1px solid rgba(255, 255, 255, 0.16);
            background: rgba(255, 255, 255, 0.05);
            color: #fff;
            font-size: 20px;
            display: grid;
            place-items: center;
            cursor: pointer;
        }

        .memory-modal h3 {
            margin: 0 0 16px;
            font-size: 32px;
            line-height: 1.1;
            letter-spacing: 0.4px;
            color: var(--text-primary);
        }

        .memory-modal-text {
            color: var(--text-secondary);
            line-height: 1.8;
            font-size: 17px;
            overflow-y: auto;
            max-height: 62vh;
            padding-right: 10px;
            text-align: left;
        }

        .memory-modal-media {
            display: none;
            float: right;
            width: min(42%, 300px);
            margin: 0 0 14px 18px;
            gap: 10px;
        }

        .memory-modal-media img {
            width: 100%;
            height: auto;
            max-height: 320px;
            object-fit: contain;
            border-radius: 0;
            border: none;
            background: transparent;
            display: block;
            margin-bottom: 10px;
        }

        .memory-modal-media img:last-child {
            margin-bottom: 0;
        }

        .memory-modal-image-full .memory-modal-text {
            display: flex;
            align-items: center;
            justify-content: center;
            padding-right: 0;
            text-align: center;
        }

        .memory-modal-image-full .memory-modal-media {
            float: none;
            width: 100%;
            max-width: 100%;
            margin: 0;
        }

        .memory-modal-image-full .memory-modal-media img {
            width: auto;
            max-width: 100%;
            max-height: 68vh;
            margin: 0 auto 10px;
        }

        .memory-modal-text::after {
            content: '';
            display: block;
            clear: both;
        }

        .memory-modal-text::-webkit-scrollbar {
            width: 7px;
        }

        .memory-modal-text::-webkit-scrollbar-thumb {
            background: rgba(255, 255, 255, 0.12);
            border-radius: 999px;
        }

        .memory-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
            border-color: rgba(255, 255, 255, 0.16);
        }

        .memory-card h3 {
            margin: 0 0 12px;
            font-size: 24px;
            font-weight: 400;
            letter-spacing: 0.5px;
            color: var(--text-primary);
            line-height: 1.2;
            text-align: left;
        }

        .memory-card p {
            margin: 0;
            color: var(--text-secondary);
            line-height: 1.75;
            font-size: 16px;
            text-align: left;
        }

        .memory-card h3,
        .memory-card p,
        .memory-modal h3,
        .memory-modal-text {
            overflow-wrap: anywhere;
            word-break: break-word;
            hyphens: auto;
        }

        .memory-card::after {
            content: '""';
            position: absolute;
            top: 16px;
            right: 18px;
            font-size: 72px;
            color: rgba(255, 255, 255, 0.08);
            line-height: 1;
        }

        #langSwitch {
            position: absolute;
            top: 20px;
            right: 20px;
        }

        #langSwitch button {
            background: none;
            color: #fff;
            border: 1px solid #444;
            padding: 5px 10px;
            cursor: pointer;
            margin-left: 5px;
            transition: .3s;
            display: inline-block;
        }

        @media (max-width: 820px) {
            header {
                align-items: center;
                padding-top: 28px;
            }

            .memories-container {
                grid-template-columns: 1fr;
                gap: 16px;
            }

            .memory-card {
                max-height: none;
                min-height: 0;
                padding: 20px 16px 18px;
                border-radius: 18px;
                overflow: hidden;
            }

            .memory-card .memory-content {
                overflow: visible;
                padding-right: 0;
            }

            .memory-card-media {
                float: none;
                width: 100%;
                max-width: 240px;
                margin: 0 0 12px;
            }

            .memory-card::after {
                display: none;
            }

            .memory-card::before {
                display: none;
            }

            .memory-modal {
                padding: 10px;
            }

            .memory-modal-panel {
                width: min(420px, 100%);
                border-radius: 18px;
                padding: 20px 14px 14px;
            }

            .memory-modal h3 {
                font-size: 24px;
                line-height: 1.2;
                padding-right: 42px;
            }

            .memory-modal-text {
                font-size: 15px;
                line-height: 1.65;
                max-height: 68vh;
                padding-right: 4px;
            }

            .memory-modal-media {
                float: none;
                width: 100%;
                max-width: 100%;
                margin: 0 0 10px;
            }

            .global-contact {
                font-size: 15px;
                line-height: 1.6;
                padding: 18px 16px 22px;
            }

            #langSwitch {
                position: static;
                margin: 0 auto 12px;
                text-align: center;
            }

            #langSwitch button {
                margin: 0 8px;
                padding: 10px 14px;
                font-size: 16px;
                min-width: 70px;
            }

            nav {
                display: flex;
                flex-wrap: wrap;
                justify-content: center;
                gap: 8px;
                width: 100%;
            }

            nav a {
                margin: 6px 4px;
                padding: 14px 16px;
                font-size: 22px;
                line-height: 1.3;
                min-width: 130px;
                border-radius: 12px;
                background: rgba(255, 255, 255, 0.08);
                border: 1px solid rgba(255, 255, 255, 0.12);
                text-align: center;
                box-shadow: inset 0 0 0 1px rgba(255,255,255,0.02);
            }
        }

        #langSwitch button.active {
            background: #fff;
            color: #000;
            border-color: #fff;
        }

        /* Scholar link */
        .scholar-link {
            margin: 25px 0;
        }

        .scholar-link a {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            color: #ccc;
            text-decoration: none;
            font-size: 16px;
            transition: .3s;
        }

        .scholar-link a:hover {
            color: #fff;
        }

        .scholar-icon {
            width: 22px;
            height: 22px;
            fill: #fff;
        }

        /* Publications */
        .pub-list {
            max-width: 1000px;
            margin: 40px auto 0;
            text-align: left;
        }

        .pub {
            margin-bottom: 18px;
            padding-bottom: 14px;
            border-bottom: 1px solid #222;
        }

        .pub-title {
            color: #fff;
            font-size: 17px;
        }

        .pub-meta {
            color: #aaa;
            font-size: 14px;
            margin-top: 4px;
        }

        .pub-authors {
            color: #ddd;
            font-size: 15px;
            margin-top: 4px;
        }

        .pub a {
            color: #9ad;
            text-decoration: none;
        }

        .pub a:hover {
            text-decoration: underline;
        }

        /* Responsive Design */
        @media (max-width: 768px) {
            .gallery {
                grid-template-columns: 1fr;
                gap: 20px;
            }

            .gallery img {
                height: auto;
            }

            .gallery-tabs {
                gap: 10px;
                margin: 40px 0 50px 0;
            }

            .tab-btn {
                font-size: 16px;
                letter-spacing: 4px;
                padding: 10px 20px;
            }

            .photo-subsection h3 {
                font-size: 20px;
                letter-spacing: 3px;
            }

            .photo-subsection h3 .year {
                font-size: 12px;
                letter-spacing: 1px;
                margin-top: 3px;
            }

            h1 {
                font-size: 28px;
            }

            h2 {
                font-size: 22px;
            }

            header nav a {
                font-size: 14px;
            }
        }

        @media (min-width: 769px) and (max-width: 1024px) {
            .gallery {
                grid-template-columns: repeat(2, 1fr);
            }

            .tab-btn {
                font-size: 18px;
                letter-spacing: 5px;
            }
        }

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

.caption {
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
}

.carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.carousel-row {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    gap: 20px;
    padding: 10px 0;
}

.carousel-item {
    min-width: min(320px, 100%);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

.carousel-item img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    cursor: pointer;
    filter: grayscale(100%);
    transition: 0.3s;
}

.carousel-item img:hover {
    filter: grayscale(0%);
    transform: scale(1.02);
}

.caption {
    margin-top: 6px;
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
}

/* arrows */
.arrow {
    font-size: 40px;
    cursor: pointer;
    user-select: none;
    padding: 10px;
    color: white;
    opacity: 0.6;
}

.arrow:hover {
    opacity: 1;
}

.arrow.left { margin-right: 10px; }
.arrow.right { margin-left: 10px; }

.strip-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
}

.strip {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin-top: 20px;
    justify-content: center;
    width: 100%;
}

.strip-item {
    display: flex;
    flex-direction: column;
    width: min(100%, 20rem);
    gap: 10px;
}

.strip-item a {
    display: block;
    overflow: hidden;
    border-radius: 4px;
}

.strip img {
    width: 100%;
    max-width: 320px;
    height: auto;
    display: block;
    object-fit: contain;
    filter: grayscale(100%);
    transition: transform 0.3s ease, filter 0.3s ease;
    cursor: pointer;
}

.strip img:hover {
    filter: grayscale(0%);
    transform: scale(1.02);
}

.strip-arrow {
    font-size: 32px;
    cursor: pointer;
    user-select: none;
    opacity: 0.6;
}

.strip-arrow:hover {
    opacity: 1;
}

.strip-item .caption {
    display: block;
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 4px;
    line-height: 1.5;
    text-align: left;
    word-break: break-word;
}

.preview-hidden {
    display: none !important;
}

.gallery-show-more {
    margin: 18px auto 6px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    border-radius: 999px;
    background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
    color: #fff;
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 6px 18px rgba(0,0,0,0.45);
    cursor: pointer;
    font-size: 15px;
    transition: transform .12s ease, box-shadow .12s ease, opacity .12s ease;
    opacity: 0.98;
}

.gallery-show-more:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(0,0,0,0.5); }

.gallery-show-more::after { content: '▸'; font-size: 14px; opacity: 0.9 }

/* Caption overlay for PhotoSwipe fallback */
#pswp-caption-overlay {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 28px;
    max-width: 90%;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    line-height: 1.4;
    z-index: 1000;
    box-shadow: 0 6px 20px rgba(0,0,0,0.5);
    text-align: center;
}

@media (max-width: 480px) {
    #pswp-caption-overlay {
        bottom: 14px;
        font-size: 13px;
        padding: 8px 10px;
    }
}

#pswp-caption-overlay[style*="display: none"] {
    display: none !important;
}

/* Make overlay visually present but let clicks pass through to underlying lightbox controls */
#pswp-caption-overlay {
    pointer-events: none;
    max-height: 40vh;
    overflow: auto;
}

/* Custom Lightbox styles */
#custom-lightbox{display:none}
#custom-lightbox.open{display:block}
#custom-lightbox .clb-backdrop{position:fixed;inset:0;background:rgba(0,0,0,0.75);z-index:10000}
#custom-lightbox .clb-shell{position:fixed;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;z-index:10001;padding:10px 8px 12px;box-sizing:border-box;pointer-events:none;overflow:auto}
#custom-lightbox .clb-shell > * { pointer-events:auto; }
#custom-lightbox .clb-stage{width:auto;max-width:calc(100vw - 90px);max-height:calc(100dvh - 108px);display:flex;flex-direction:column;align-items:center;justify-content:flex-start;position:relative;z-index:1;overflow:auto;padding-bottom:4px}
#custom-lightbox img.clb-img{display:block;width:auto;height:auto;max-width:calc(100vw - 90px);max-height:calc(100dvh - 210px);border-radius:4px;box-shadow:0 6px 30px rgba(0,0,0,0.6);object-fit:contain;overflow:visible}
#custom-lightbox video.clb-video{display:block;width:auto;height:auto;max-width:calc(100vw - 90px);max-height:calc(100dvh - 210px);border-radius:4px;box-shadow:0 6px 30px rgba(0,0,0,0.6);background:#000;object-fit:contain;overflow:visible}
#custom-lightbox .clb-caption{color:#fff;margin-top:10px;max-width:90vw;text-align:center}
#custom-lightbox .clb-nav{display:flex;align-items:center;justify-content:center;gap:16px;margin-top:10px;padding:8px 10px;border-radius:999px;background:rgba(0,0,0,0.38)}

#custom-lightbox .clb-close, #custom-lightbox .clb-prev, #custom-lightbox .clb-next {
    background: rgba(0,0,0,0.55);
    border: none;
    color: #fff;
    font-size: 42px;
    padding: 0;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10002;
    backdrop-filter: blur(6px);
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: transform 0.16s ease, background-color 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;
}
#custom-lightbox .clb-prev, #custom-lightbox .clb-next { position: static; }
#custom-lightbox .clb-close{position:absolute;right:18px;top:18px}
#custom-lightbox .clb-close{right:18px;top:18px}

#custom-lightbox .clb-close:hover,
#custom-lightbox .clb-prev:hover,
#custom-lightbox .clb-next:hover {
    background: rgba(255,255,255,0.22);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 14px 34px rgba(0,0,0,0.58);
}

#custom-lightbox .clb-close:active,
#custom-lightbox .clb-prev:active,
#custom-lightbox .clb-next:active {
    transform: scale(0.96);
}

#custom-lightbox .clb-close:focus-visible,
#custom-lightbox .clb-prev:focus-visible,
#custom-lightbox .clb-next:focus-visible {
    outline: 2px solid rgba(255,255,255,0.95);
    outline-offset: 3px;
    background: rgba(255,255,255,0.24);
}

@media (max-width:900px){
    #custom-lightbox .clb-shell{padding:10px 14px}
    #custom-lightbox .clb-stage,
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-width:calc(100vw - 20px)}
    #custom-lightbox .clb-stage{max-height:calc(100dvh - 104px)}
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-height:calc(100dvh - 198px)}
    #custom-lightbox .clb-close, #custom-lightbox .clb-prev, #custom-lightbox .clb-next{
        font-size:40px;
        width:64px;
        height:64px;
    }
}

@media (max-width:600px){
    #custom-lightbox .clb-shell{padding:8px 10px}
    #custom-lightbox .clb-stage,
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-width:calc(100vw - 12px)}
    #custom-lightbox .clb-stage{max-height:calc(100dvh - 98px)}
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-height:calc(100dvh - 186px)}
    #custom-lightbox .clb-close, #custom-lightbox .clb-prev, #custom-lightbox .clb-next{
        width:56px;
        height:56px;
        font-size:36px;
    }
    #custom-lightbox .clb-close{ right: 10px; top: 10px }
    #custom-lightbox .clb-caption{font-size:14px;padding:0 8px}
}

@media (max-width:390px){
    #custom-lightbox .clb-shell{padding:8px 8px}
    #custom-lightbox .clb-stage,
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-width:calc(100vw - 8px)}
    #custom-lightbox .clb-stage{max-height:calc(100dvh - 94px)}
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-height:calc(100dvh - 176px)}
    #custom-lightbox .clb-close, #custom-lightbox .clb-prev, #custom-lightbox .clb-next{
        width:52px;
        height:52px;
        font-size:32px;
    }
    #custom-lightbox .clb-close{ right: 8px; top: 8px }
}

@media (max-height:560px){
    #custom-lightbox .clb-stage{max-height:calc(100dvh - 86px)}
    #custom-lightbox img.clb-img,
    #custom-lightbox video.clb-video{max-height:calc(100dvh - 166px)}
    #custom-lightbox .clb-caption{margin-top:6px;font-size:13px;line-height:1.35}
    #custom-lightbox .clb-nav{margin-top:8px;padding:6px 8px;gap:10px}
    #custom-lightbox .clb-close,
    #custom-lightbox .clb-prev,
    #custom-lightbox .clb-next{width:44px;height:44px;font-size:28px}
    #custom-lightbox .clb-close{right:6px;top:6px}
}
