/* Public gallery comments. Loaded only by submissions.php. */
@media all {
    body.bluecg-public-gallery-page main > .bluecg-nav {
        position: static;
        inset: auto;
        z-index: auto;
    }

    body.bluecg-public-gallery-page .bluecg-section-title {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: .75rem;
    }

    body.bluecg-public-gallery-page .bluecg-section-title > div {
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-section-title h2,
    body.bluecg-public-gallery-page .bluecg-section-title p {
        max-width: none;
        overflow-wrap: normal;
        white-space: normal;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-actions {
        display: grid;
        grid-template-columns: repeat(4, minmax(7.4rem, 1fr)) minmax(13rem, 1.35fr);
        align-items: center;
        gap: .55rem;
        margin: .95rem 0 1rem;
        padding: .5rem;
        border: 1px solid rgba(36, 120, 117, .13);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 252, .92), rgba(248, 244, 234, .82));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .72rem 1.55rem rgba(48, 38, 26, .07);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action,
    body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
        min-height: 2.62rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: .45rem;
        min-width: 0;
        padding: .58rem .9rem;
        border: 1px solid rgba(36, 120, 117, .15);
        border-radius: .82rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(249, 245, 235, .78));
        color: #2f2a24;
        font-size: .86rem;
        font-weight: 950;
        line-height: 1.2;
        text-decoration: none;
        text-align: center;
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, .76);
        transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease, color .18s ease;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action::before,
    body.bluecg-public-gallery-page .bluecg-gallery-entry-state::before {
        content: "";
        flex: 0 0 auto;
        width: .45rem;
        height: .45rem;
        border-radius: 999px;
        background: currentColor;
        opacity: .52;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.primary {
        border-color: rgba(36, 120, 117, .42);
        background:
            linear-gradient(180deg, rgba(55, 174, 164, .96), rgba(31, 119, 116, .96));
        color: #fffefa;
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .3),
            0 .65rem 1.25rem rgba(31, 119, 116, .18);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.secondary {
        color: #50473f;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.login {
        border-color: rgba(36, 120, 117, .28);
        background:
            linear-gradient(180deg, rgba(242, 255, 252, .96), rgba(230, 249, 245, .86));
        color: #1f6f69;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.vote {
        border-color: rgba(80, 104, 180, .25);
        background:
            linear-gradient(180deg, rgba(247, 249, 255, .96), rgba(233, 239, 255, .84));
        color: #405f9f;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.result {
        border-color: rgba(157, 112, 42, .24);
        background:
            linear-gradient(180deg, rgba(255, 251, 241, .96), rgba(250, 238, 212, .86));
        color: #806023;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.is-muted {
        border-color: rgba(88, 78, 66, .12);
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .88), rgba(245, 241, 232, .72));
        color: #786d62;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action:hover,
    body.bluecg-public-gallery-page .bluecg-gallery-entry-action:focus-visible {
        border-color: rgba(36, 120, 117, .44);
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .8),
            0 .62rem 1.18rem rgba(36, 120, 117, .12);
        outline: none;
        transform: translateY(-1px);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
        justify-content: flex-start;
        justify-self: stretch;
        border-color: rgba(36, 120, 117, .18);
        background:
            linear-gradient(180deg, rgba(235, 251, 247, .9), rgba(248, 253, 250, .78));
        color: #1f6f69;
        overflow-wrap: anywhere;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-note {
        display: inline-flex;
        justify-content: center;
        width: min(100%, 64rem);
        min-height: 2.4rem;
        margin: -.45rem auto 1rem;
        padding: .5rem .75rem;
        text-decoration: none;
    }

    body.bluecg-public-gallery-page a.bluecg-gallery-entry-note:hover,
    body.bluecg-public-gallery-page a.bluecg-gallery-entry-note:focus-visible {
        border-color: rgba(36, 120, 117, .32);
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .78),
            0 .5rem .95rem rgba(36, 120, 117, .1);
        outline: none;
        transform: translateY(-1px);
    }

    body.bluecg-public-gallery-page .bluecg-category-nav {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(7.4rem, 1fr));
        justify-content: center;
        align-items: stretch;
        width: min(100%, 46rem);
        max-width: 100%;
        margin: 1rem auto 1.08rem;
        padding: .38rem;
        gap: .38rem;
        overflow: visible;
        border: 1px solid rgba(36, 120, 117, .12);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 252, .92), rgba(248, 243, 232, .82));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .84),
            0 .75rem 1.45rem rgba(48, 38, 26, .07);
        scrollbar-width: none;
    }

    body.bluecg-public-gallery-page .bluecg-category-nav::-webkit-scrollbar {
        display: none;
    }

    body.bluecg-public-gallery-page .bluecg-category-nav a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 0;
        min-height: 2.45rem;
        padding: .55rem .75rem;
        border: 1px solid transparent;
        border-radius: .76rem;
        background: rgba(255, 255, 252, .64);
        color: #5d544b;
        font-size: .85rem;
        font-weight: 950;
        line-height: 1.18;
        text-align: center;
        text-decoration: none;
        white-space: nowrap;
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, .74);
        transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease, color .18s ease;
    }

    body.bluecg-public-gallery-page .bluecg-category-nav a:hover,
    body.bluecg-public-gallery-page .bluecg-category-nav a:focus-visible,
    body.bluecg-public-gallery-page .bluecg-category-nav a.active {
        border-color: rgba(36, 120, 117, .36);
        background:
            linear-gradient(180deg, rgba(237, 253, 249, .98), rgba(226, 248, 244, .88));
        color: #1f7774;
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .5rem 1rem rgba(36, 120, 117, .12);
        outline: none;
        transform: translateY(-1px);
    }

    body.bluecg-public-gallery-page .bluecg-public-showcase-grid {
        grid-template-columns: repeat(auto-fill, minmax(min(100%, 18.5rem), 1fr));
        justify-items: stretch;
        align-items: start;
        gap: 1.05rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: .78rem;
        align-content: start;
        max-width: none;
        height: 100%;
        padding: .72rem;
        overflow: hidden;
        border-color: rgba(36, 120, 117, .14);
        background:
            linear-gradient(180deg, rgba(255, 255, 252, .96), rgba(250, 246, 235, .88));
        box-shadow: 0 .9rem 1.9rem rgba(42, 35, 24, .08);
        transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card:hover,
    body.bluecg-public-gallery-page .bluecg-public-work-card:focus-within {
        border-color: rgba(36, 120, 117, .28);
        box-shadow: 0 1.15rem 2.3rem rgba(42, 35, 24, .13);
        transform: translateY(-2px);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
        border-color: rgba(36, 120, 117, .34);
        box-shadow: 0 1.35rem 2.7rem rgba(31, 119, 116, .14);
    }

    @media (min-width: 720px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
            grid-column: span 2;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main {
            aspect-ratio: 16 / 10;
        }
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media {
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
        min-height: 0;
        max-height: none;
        aspect-ratio: 1 / 1;
        border-radius: .92rem;
        background:
            radial-gradient(circle at 50% 38%, rgba(255, 255, 255, .95), rgba(250, 246, 236, .78) 58%, rgba(230, 245, 242, .72)),
            repeating-linear-gradient(45deg, rgba(36, 120, 117, .045) 0 .45rem, rgba(255, 255, 255, 0) .45rem .9rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
        transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:hover,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:focus-visible {
        border-color: rgba(36, 120, 117, .42);
        box-shadow: inset 0 0 0 1px rgba(36, 120, 117, .12), 0 .72rem 1.3rem rgba(36, 120, 117, .1);
        outline: none;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main img,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb > img {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        transition: transform .22s ease;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:hover img,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:focus-visible img {
        transform: scale(1.025);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-body {
        display: grid;
        gap: .62rem;
        align-content: start;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-actions {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: .45rem .6rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-work-expand {
        min-height: 2.28rem;
        padding: .48rem .78rem;
        border: 1px solid rgba(36, 120, 117, .2);
        border-radius: .7rem;
        background: linear-gradient(180deg, rgba(246, 255, 252, .95), rgba(227, 248, 244, .86));
        color: #247875;
        cursor: pointer;
        font: inherit;
        font-size: .82rem;
        font-weight: 950;
        line-height: 1.1;
        transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
    }

    body.bluecg-public-gallery-page .bluecg-work-expand:hover,
    body.bluecg-public-gallery-page .bluecg-work-expand:focus-visible {
        border-color: rgba(36, 120, 117, .42);
        box-shadow: 0 .5rem .95rem rgba(36, 120, 117, .1);
        outline: none;
        transform: translateY(-1px);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-expand {
        background: linear-gradient(180deg, rgba(255, 255, 255, .94), rgba(248, 239, 222, .86));
        color: #5d4d34;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-actions span {
        color: #766c61;
        font-size: .76rem;
        font-weight: 760;
        line-height: 1.35;
    }

    body.bluecg-public-gallery-page .bluecg-author-profile,
    body.bluecg-public-gallery-page .bluecg-author-uid {
        min-width: 0;
        color: #247875;
        text-decoration: none;
    }

    body.bluecg-public-gallery-page .bluecg-author-profile:hover,
    body.bluecg-public-gallery-page .bluecg-author-profile:focus-visible,
    body.bluecg-public-gallery-page .bluecg-author-uid:hover,
    body.bluecg-public-gallery-page .bluecg-author-uid:focus-visible {
        color: #176461;
        text-decoration: underline;
        text-underline-offset: .16em;
        outline: none;
    }

    body.bluecg-public-gallery-page .bluecg-author-profile strong {
        color: inherit;
    }

    body.bluecg-public-gallery-page .bluecg-author-uid {
        grid-column: 1 / -1;
        justify-self: start;
        font-size: .76rem;
        font-weight: 900;
        line-height: 1.35;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-details {
        display: grid;
        gap: .75rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page.js-enhanced .bluecg-public-work-card:not(.is-expanded) .bluecg-public-work-details {
        display: none;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
        animation: bluecgPublicReveal .22s ease both;
    }

    @keyframes bluecgPublicReveal {
        from {
            opacity: 0;
            transform: translateY(.35rem);
        }

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

    body.bluecg-public-gallery-page .bluecg-work-comments {
        display: grid;
        gap: .72rem;
        min-width: 0;
        margin-top: .25rem;
        padding: .78rem;
        border: 1px solid rgba(36, 120, 117, .13);
        border-radius: .9rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .9), rgba(239, 250, 247, .74));
    }

    body.bluecg-public-gallery-page .bluecg-comments-head,
    body.bluecg-public-gallery-page .bluecg-comment-meta {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: .65rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comments-head h4 {
        margin: 0;
        color: #24211d;
        font-size: .98rem;
        font-weight: 950;
        line-height: 1.25;
    }

    body.bluecg-public-gallery-page .bluecg-comments-head span,
    body.bluecg-public-gallery-page .bluecg-comment-date {
        color: #70655d;
        font-size: .76rem;
        font-weight: 780;
        line-height: 1.35;
        white-space: nowrap;
    }

    body.bluecg-public-gallery-page .bluecg-comment-list {
        display: grid;
        gap: .55rem;
    }

    body.bluecg-public-gallery-page .bluecg-comment {
        display: grid;
        gap: .34rem;
        min-width: 0;
        padding: .65rem .72rem;
        border: 1px solid rgba(83, 70, 55, .12);
        border-radius: .75rem;
        background: rgba(255, 254, 249, .82);
    }

    body.bluecg-public-gallery-page .bluecg-comment-member {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: .34rem .44rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-meta strong {
        min-width: 0;
        overflow-wrap: anywhere;
        color: #24211d;
        font-size: .86rem;
        font-weight: 950;
        line-height: 1.3;
    }

    body.bluecg-public-gallery-page .bluecg-comment-author {
        min-width: 0;
        color: #247875;
        text-decoration: none;
    }

    body.bluecg-public-gallery-page .bluecg-comment-author:hover,
    body.bluecg-public-gallery-page .bluecg-comment-author:focus-visible {
        color: #176461;
        text-decoration: underline;
        text-underline-offset: .16em;
    }

    body.bluecg-public-gallery-page .bluecg-comment-author strong {
        color: inherit;
    }

    body.bluecg-public-gallery-page .bluecg-comment-uid {
        display: inline-flex;
        align-items: center;
        min-height: 1.42rem;
        padding: .14rem .46rem;
        border: 1px solid rgba(36, 120, 117, .18);
        border-radius: 999px;
        background: rgba(232, 251, 247, .74);
        color: #247875;
        font-size: .72rem;
        font-weight: 900;
        line-height: 1;
        white-space: nowrap;
    }

    body.bluecg-public-gallery-page .bluecg-comment p,
    body.bluecg-public-gallery-page .bluecg-comment-empty,
    body.bluecg-public-gallery-page .bluecg-comment-more,
    body.bluecg-public-gallery-page .bluecg-comment-login {
        margin: 0;
        color: #514940;
        font-size: .86rem;
        font-weight: 720;
        line-height: 1.58;
        overflow-wrap: anywhere;
    }

    body.bluecg-public-gallery-page .bluecg-comment-login {
        padding: .64rem .72rem;
        border: 1px dashed rgba(36, 120, 117, .28);
        border-radius: .75rem;
        background: rgba(232, 251, 247, .56);
    }

    body.bluecg-public-gallery-page .bluecg-comment-login a {
        color: #247872;
        font-weight: 950;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form {
        display: grid;
        gap: .55rem;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form label {
        color: #24211d;
        font-size: .86rem;
        font-weight: 950;
        line-height: 1.32;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form textarea {
        width: 100%;
        min-height: 5.4rem;
        resize: vertical;
        border: 1px solid rgba(78, 68, 57, .22);
        border-radius: .78rem;
        padding: .68rem .72rem;
        background: rgba(255, 255, 255, .94);
        color: #24211d;
        font: inherit;
        line-height: 1.5;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form textarea:focus {
        border-color: rgba(36, 120, 117, .58);
        box-shadow: 0 0 0 .22rem rgba(36, 120, 117, .14);
        outline: none;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form .bluecg-button {
        display: inline-flex;
        justify-self: start;
        width: min(100%, 12rem);
        min-height: 2.55rem;
        border-radius: .75rem;
        padding: .48rem .95rem;
        font-size: .88rem;
        justify-content: center;
        text-align: center;
    }

    body.bluecg-public-gallery-page .bluecg-image-modal.is-open .bluecg-image-modal-backdrop {
        animation: bluecgPublicModalFade .18s ease both;
    }

    body.bluecg-public-gallery-page .bluecg-image-modal.is-open .bluecg-image-modal-frame {
        animation: bluecgPublicModalIn .2s ease both;
    }

    body.bluecg-public-gallery-page .bluecg-image-modal-img {
        background:
            radial-gradient(circle at 50% 45%, rgba(255, 255, 255, .08), rgba(255, 255, 255, 0) 62%);
    }

    @keyframes bluecgPublicModalFade {
        from {
            opacity: 0;
        }

        to {
            opacity: 1;
        }
    }

    @keyframes bluecgPublicModalIn {
        from {
            opacity: 0;
            transform: translateY(.45rem) scale(.985);
        }

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

    @media (max-width: 860px) {
        body.bluecg-public-gallery-page .bluecg-section-title {
            grid-template-columns: 1fr;
            align-items: start;
        }

        body.bluecg-public-gallery-page .bluecg-gallery-entry-actions {
            display: grid;
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-category-nav {
            margin: .85rem 0;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card {
            grid-template-columns: 1fr;
            padding: .82rem;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
            grid-column: auto;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb,
        body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
            min-height: 10rem;
            max-height: none;
            aspect-ratio: 1 / 1;
        }

        body.bluecg-public-gallery-page .bluecg-comments-head,
        body.bluecg-public-gallery-page .bluecg-comment-meta {
            align-items: start;
            flex-direction: column;
            gap: .18rem;
        }
    }
}

/* Public gallery user comment deletion */
@media all {
    body.bluecg-public-gallery-page .bluecg-comment-tools {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        flex-wrap: wrap;
        gap: .35rem .45rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-delete-form {
        margin: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-delete-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 1.72rem;
        padding: .18rem .52rem;
        border: 1px solid rgba(170, 66, 66, .24);
        border-radius: 999px;
        background: rgba(255, 246, 244, .86);
        color: #9b3939;
        cursor: pointer;
        font: inherit;
        font-size: .72rem;
        font-weight: 920;
        line-height: 1;
        white-space: nowrap;
        transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
    }

    body.bluecg-public-gallery-page .bluecg-comment-delete-button:hover,
    body.bluecg-public-gallery-page .bluecg-comment-delete-button:focus-visible {
        border-color: rgba(170, 66, 66, .45);
        background: rgba(255, 235, 232, .96);
        color: #7f2828;
        outline: none;
        transform: translateY(-1px);
    }

    @media (max-width: 640px) {
        body.bluecg-public-gallery-page .bluecg-comment-meta {
            align-items: flex-start;
        }

        body.bluecg-public-gallery-page .bluecg-comment-tools {
            justify-content: flex-start;
        }
    }
}

/* Superseded by the final override at the end of this file. */
@media not all {
    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state {
        border-color: rgba(36, 120, 117, .24);
        background:
            linear-gradient(180deg, rgba(237, 253, 249, .98), rgba(230, 248, 244, .88));
        color: #1f7774;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state::before {
        background: linear-gradient(90deg, #247872, #54b3a9);
        opacity: .82;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state.is-status {
        cursor: default;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state.is-status:hover {
        transform: none;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
        grid-column: 1 / -1;
        grid-template-columns: minmax(0, 1fr) !important;
        align-items: start;
        gap: 1.05rem;
        overflow: visible;
        padding: clamp(.85rem, 1.6vw, 1.2rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-body {
        min-width: 0;
        width: 100%;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-gallery {
        position: static;
        top: auto;
        width: 100%;
        max-width: 100%;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb:not(.bluecg-work-youtube):not(.is-empty) {
        min-height: 0;
        max-height: none;
        aspect-ratio: auto;
        padding: clamp(.75rem, 2vw, 1rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main {
        border-color: rgba(36, 120, 117, .24);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .96), rgba(247, 251, 248, .88)),
            repeating-linear-gradient(45deg, rgba(36, 120, 117, .035) 0 .5rem, transparent .5rem 1rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main img,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb > img {
        display: block;
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: min(72dvh, 52rem);
        margin: auto;
        object-fit: contain;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-controls {
        margin-top: .62rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-body {
        padding: .18rem;
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .82), rgba(239, 250, 247, .52));
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
        display: grid;
        grid-template-columns: minmax(0, .9fr) minmax(22rem, 1.1fr);
        gap: .9rem;
        align-items: start;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-concept,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-links {
        grid-column: 1;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-comments {
        grid-column: 2;
        grid-row: 1 / span 2;
    }

    body.bluecg-public-gallery-page .bluecg-work-comments {
        gap: .9rem;
        padding: 1rem;
        border-color: rgba(36, 120, 117, .18);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .96), rgba(236, 250, 247, .82));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .75rem 1.55rem rgba(36, 120, 117, .08);
    }

    body.bluecg-public-gallery-page .bluecg-comments-head {
        padding-bottom: .65rem;
        border-bottom: 1px solid rgba(36, 120, 117, .12);
    }

    body.bluecg-public-gallery-page .bluecg-comments-head h4 {
        font-size: 1.02rem;
    }

    body.bluecg-public-gallery-page .bluecg-comments-head span {
        display: inline-flex;
        align-items: center;
        min-height: 1.75rem;
        padding: .18rem .52rem;
        border: 1px solid rgba(36, 120, 117, .16);
        border-radius: 999px;
        background: rgba(239, 253, 249, .82);
        color: #247872;
    }

    body.bluecg-public-gallery-page .bluecg-comment {
        border-color: rgba(36, 120, 117, .12);
        border-radius: .9rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .92), rgba(255, 250, 239, .78));
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, .74);
    }

    body.bluecg-public-gallery-page .bluecg-comment-empty,
    body.bluecg-public-gallery-page .bluecg-comment-more,
    body.bluecg-public-gallery-page .bluecg-comment-login {
        padding: .78rem .86rem;
        border: 1px dashed rgba(36, 120, 117, .22);
        border-radius: .86rem;
        background: rgba(255, 254, 249, .72);
    }

    body.bluecg-public-gallery-page .bluecg-comment-form {
        gap: .68rem;
        padding: .9rem;
        border: 1px solid rgba(36, 120, 117, .2);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(237, 253, 249, .96), rgba(255, 254, 249, .88));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .7rem 1.45rem rgba(36, 120, 117, .08);
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head {
        display: flex;
        align-items: center;
        gap: .65rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-avatar {
        display: grid;
        place-items: center;
        flex: 0 0 auto;
        width: 2.35rem;
        height: 2.35rem;
        border: 1px solid rgba(36, 120, 117, .22);
        border-radius: .8rem;
        background:
            linear-gradient(180deg, rgba(57, 178, 168, .98), rgba(31, 119, 116, .96));
        color: #fffefa;
        font-size: .9rem;
        font-weight: 950;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head > div {
        display: grid;
        gap: .12rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head strong {
        color: #24211d;
        font-size: .9rem;
        font-weight: 950;
        line-height: 1.28;
        overflow-wrap: anywhere;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head span:not(.bluecg-comment-avatar) {
        color: #247872;
        font-size: .75rem;
        font-weight: 900;
        line-height: 1.25;
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: .62rem;
        align-items: stretch;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose textarea {
        min-height: 5rem;
        border-color: rgba(36, 120, 117, .22);
        background: rgba(255, 255, 253, .96);
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose .bluecg-button {
        align-self: stretch;
        min-width: 7.4rem;
        width: auto;
        margin: 0;
    }

    @media (max-width: 920px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-concept,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-links,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-comments {
            grid-column: 1;
            grid-row: auto;
        }
    }

    @media (max-width: 640px) {
        body.bluecg-public-gallery-page .bluecg-comment-compose {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-comment-compose .bluecg-button {
            width: 100%;
            min-height: 2.65rem;
        }
    }
}

/* Public gallery final presentation pass. Loaded only on submissions.php. */
@media all {
    body.bluecg-public-gallery-page .bluecg-shell.wide {
        width: min(100% - 1.25rem, 90rem);
    }

    body.bluecg-public-gallery-page .bluecg-showcase-panel {
        position: relative;
        overflow: clip;
    }

    body.bluecg-public-gallery-page .bluecg-showcase-panel::after {
        position: absolute;
        inset: 0;
        z-index: 0;
        content: "";
        pointer-events: none;
        background:
            linear-gradient(90deg, rgba(36, 120, 117, .09), transparent 21rem),
            linear-gradient(270deg, rgba(187, 121, 37, .08), transparent 23rem),
            repeating-linear-gradient(135deg, rgba(36, 120, 117, .035) 0 1px, transparent 1px 1.2rem);
        opacity: .62;
        mask-image: linear-gradient(180deg, rgba(0, 0, 0, .72), transparent 36rem);
    }

    body.bluecg-public-gallery-page .bluecg-showcase-panel > .bluecg-panel-inner {
        position: relative;
        z-index: 1;
    }

    body.bluecg-public-gallery-page .bluecg-section-title {
        margin-bottom: 1rem;
        padding-bottom: .9rem;
        border-bottom: 1px solid rgba(72, 59, 45, .1);
    }

    body.bluecg-public-gallery-page .bluecg-section-title h2 {
        letter-spacing: 0;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-actions {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        width: min(100%, 64rem);
        margin: 1rem auto 1.05rem;
        padding: .45rem;
        gap: .42rem;
        border-color: rgba(36, 120, 117, .16);
        border-radius: 1.05rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .94), rgba(248, 244, 235, .84));
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action,
    body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
        min-height: 2.85rem;
        padding: .58rem .7rem;
        border-radius: .8rem;
        font-size: .84rem;
        letter-spacing: 0;
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .78),
            0 .28rem .75rem rgba(44, 35, 25, .04);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action::before,
    body.bluecg-public-gallery-page .bluecg-gallery-entry-state::before {
        width: .48rem;
        height: 1.35rem;
        border-radius: 999px;
        opacity: .7;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-action.primary {
        background:
            linear-gradient(180deg, rgba(57, 178, 168, .98), rgba(31, 119, 116, .98));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .3),
            0 .7rem 1.35rem rgba(31, 119, 116, .2);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
        justify-content: center;
        color: #1f6f69;
    }

    body.bluecg-public-gallery-page .bluecg-category-nav {
        grid-template-columns: repeat(auto-fit, minmax(8.2rem, 1fr));
        width: min(100%, 58rem);
        margin: 1.05rem auto 1.25rem;
        padding: .42rem;
        border-radius: 1.05rem;
    }

    body.bluecg-public-gallery-page .bluecg-category-nav a {
        min-height: 2.6rem;
        padding: .58rem .82rem;
        border-radius: .78rem;
        white-space: normal;
    }

    body.bluecg-public-gallery-page .bluecg-public-showcase-grid {
        grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr));
        grid-auto-flow: dense;
        gap: 1.15rem;
        align-items: stretch;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card {
        position: relative;
        isolation: isolate;
        gap: .86rem;
        height: auto;
        min-height: 100%;
        padding: .78rem;
        border-color: rgba(36, 120, 117, .15);
        border-radius: 1.05rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .97), rgba(250, 246, 236, .9));
        box-shadow:
            0 .95rem 2.1rem rgba(42, 35, 24, .085),
            inset 0 1px 0 rgba(255, 255, 255, .82);
        transform: translateY(0);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card::before {
        position: absolute;
        inset: 0 0 auto;
        z-index: 0;
        height: 3px;
        content: "";
        background: linear-gradient(90deg, #247872, #d49a3f, #a45b67);
        opacity: .82;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card > * {
        position: relative;
        z-index: 1;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card:hover,
    body.bluecg-public-gallery-page .bluecg-public-work-card:focus-within {
        border-color: rgba(36, 120, 117, .33);
        box-shadow:
            0 1.25rem 2.6rem rgba(42, 35, 24, .13),
            inset 0 1px 0 rgba(255, 255, 255, .86);
        transform: translateY(-3px);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
        border-color: rgba(36, 120, 117, .38);
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .98), rgba(246, 251, 247, .92));
        box-shadow:
            0 1.45rem 3.2rem rgba(31, 119, 116, .16),
            inset 0 1px 0 rgba(255, 255, 255, .88);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-gallery {
        gap: .55rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
        min-height: 11.75rem;
        aspect-ratio: 16 / 10;
        border-radius: .9rem;
        background:
            radial-gradient(circle at 50% 42%, rgba(255, 255, 255, .98), rgba(250, 246, 236, .82) 62%, rgba(232, 246, 243, .72)),
            linear-gradient(135deg, rgba(255, 255, 255, .7), rgba(231, 246, 243, .36)),
            repeating-linear-gradient(45deg, rgba(36, 120, 117, .042) 0 .46rem, transparent .46rem .92rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
        border-color: rgba(36, 120, 117, .18);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-youtube {
        min-height: 0;
        max-height: none;
        aspect-ratio: auto;
        padding: .55rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-youtube .bluecg-content-video {
        min-height: 9.5rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-youtube .bluecg-content-video {
        min-height: clamp(14rem, 34vw, 28rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main::after {
        position: absolute;
        inset: auto .62rem .62rem auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 1.55rem;
        padding: .18rem .48rem;
        border: 1px solid rgba(255, 255, 255, .45);
        border-radius: 999px;
        background: rgba(25, 20, 16, .58);
        color: #fffefa;
        content: "查看原圖";
        font-size: .68rem;
        font-weight: 900;
        line-height: 1;
        opacity: 0;
        transform: translateY(.2rem);
        transition: opacity .18s ease, transform .18s ease;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:hover::after,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:focus-visible::after {
        opacity: 1;
        transform: translateY(0);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main img,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb > img {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        image-rendering: auto;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:hover img,
    body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main:focus-visible img {
        transform: scale(1.012);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-controls {
        grid-template-columns: 2.55rem minmax(0, 1fr) 2.55rem;
        gap: .42rem;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-controls > button,
    body.bluecg-public-gallery-page .bluecg-gallery-thumbs button {
        width: 2.55rem;
        height: 2.55rem;
        border-radius: .72rem;
    }

    body.bluecg-public-gallery-page .bluecg-gallery-thumbs button {
        background: rgba(255, 255, 253, .86);
    }

    body.bluecg-public-gallery-page .bluecg-gallery-thumbs button.active {
        border-color: rgba(36, 120, 117, .7);
        box-shadow: 0 0 0 .18rem rgba(36, 120, 117, .13);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-body {
        gap: .68rem;
    }

    body.bluecg-public-gallery-page .bluecg-showcase-head {
        gap: .58rem;
    }

    body.bluecg-public-gallery-page .bluecg-showcase-head h3 {
        margin-top: .34rem;
        color: #211f1d;
        font-size: 1.08rem;
        font-weight: 950;
        line-height: 1.32;
        letter-spacing: 0;
    }

    body.bluecg-public-gallery-page .bluecg-vote-pill {
        justify-self: end;
        border-color: rgba(36, 120, 117, .2);
        background: rgba(232, 251, 247, .78);
        color: #247872;
    }

    body.bluecg-public-gallery-page .bluecg-author-line {
        grid-template-columns: auto minmax(0, 1fr);
        padding: .55rem .62rem;
        border-radius: .78rem;
        background: rgba(255, 254, 249, .78);
    }

    body.bluecg-public-gallery-page .bluecg-author-line > span:first-child {
        color: #766c61;
        font-weight: 900;
    }

    body.bluecg-public-gallery-page .bluecg-author-profile {
        overflow-wrap: anywhere;
    }

    body.bluecg-public-gallery-page .bluecg-author-uid {
        grid-column: 2;
        padding-top: .08rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-actions {
        display: grid;
        grid-template-columns: minmax(7.8rem, auto) minmax(0, 1fr);
        gap: .5rem;
        align-items: center;
    }

    body.bluecg-public-gallery-page .bluecg-work-expand {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 2.55rem;
        padding: .55rem .9rem;
        border-radius: .78rem;
        background: linear-gradient(180deg, rgba(239, 253, 249, .98), rgba(222, 248, 244, .88));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .78),
            0 .45rem .95rem rgba(36, 120, 117, .08);
    }

    body.bluecg-public-gallery-page .bluecg-work-expand::after {
        content: "";
        width: .45rem;
        height: .45rem;
        margin-left: .48rem;
        border-right: 2px solid currentColor;
        border-bottom: 2px solid currentColor;
        transform: rotate(45deg) translateY(-.12rem);
        transition: transform .18s ease;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-expand::after {
        transform: rotate(225deg) translate(.04rem, -.04rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-actions span {
        color: #6d6258;
        font-size: .78rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-details[hidden] {
        display: none !important;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-details {
        gap: .82rem;
        padding-top: .18rem;
    }

    body.bluecg-public-gallery-page .bluecg-showcase-concept {
        display: block;
        min-height: 0;
        padding: .8rem .86rem;
        border: 1px solid rgba(83, 70, 55, .11);
        border-radius: .85rem;
        background: rgba(255, 254, 249, .76);
        color: #3f3933;
        font-size: .9rem;
        font-weight: 680;
        line-height: 1.72;
        -webkit-line-clamp: unset;
    }

    body.bluecg-public-gallery-page .bluecg-showcase-links {
        display: flex;
        flex-wrap: wrap;
        gap: .46rem;
    }

    body.bluecg-public-gallery-page .bluecg-work-comments {
        padding: .86rem;
        border-color: rgba(36, 120, 117, .16);
        border-radius: .9rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .92), rgba(237, 250, 247, .78));
    }

    body.bluecg-public-gallery-page .bluecg-comment-form .bluecg-button {
        background:
            linear-gradient(180deg, #35aaa4, #247872);
    }

    body.bluecg-public-gallery-page .bluecg-public-showcase-grid > .bluecg-empty {
        display: grid;
        place-items: center;
        min-height: 8rem;
        margin: 0;
        border: 1px dashed rgba(36, 120, 117, .24);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .84), rgba(239, 250, 247, .7));
        color: #5d544b;
        font-weight: 900;
    }

    body.bluecg-public-gallery-page .bluecg-image-modal-frame {
        width: min(96vw, 86rem);
        height: min(92dvh, 58rem);
        padding: clamp(2.8rem, 4vw, 4rem);
        border-radius: 1.05rem;
        background:
            linear-gradient(180deg, rgba(22, 19, 16, .92), rgba(13, 12, 11, .9));
    }

    body.bluecg-public-gallery-page .bluecg-image-modal-img {
        max-width: 100%;
        max-height: 100%;
        box-shadow: 0 1.2rem 3rem rgba(0, 0, 0, .35);
    }

    @media (min-width: 920px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
            grid-column: 1 / -1;
            grid-template-columns: minmax(0, 1.22fr) minmax(23rem, .92fr);
            gap: 1.1rem;
            padding: 1rem;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main {
            min-height: clamp(18rem, 30vw, 28rem);
            aspect-ratio: 16 / 10;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-body {
            align-content: start;
            padding-top: .2rem;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-head {
            grid-template-columns: minmax(0, 1fr) auto;
        }
    }

    @media (max-width: 1100px) {
        body.bluecg-public-gallery-page .bluecg-gallery-entry-actions {
            grid-template-columns: repeat(3, minmax(0, 1fr));
        }

        body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
            grid-column: span 2;
        }
    }

    @media (max-width: 720px) {
        body.bluecg-public-gallery-page .bluecg-shell.wide {
            width: min(100% - .75rem, 100%);
            padding-inline: 0;
        }

        body.bluecg-public-gallery-page .bluecg-section-title {
            gap: .55rem;
        }

        body.bluecg-public-gallery-page .bluecg-section-title .bluecg-pill {
            justify-self: start;
        }

        body.bluecg-public-gallery-page .bluecg-gallery-entry-actions,
        body.bluecg-public-gallery-page .bluecg-category-nav {
            grid-template-columns: 1fr 1fr;
            width: 100%;
        }

        body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
            grid-column: 1 / -1;
        }

        body.bluecg-public-gallery-page .bluecg-public-showcase-grid {
            grid-template-columns: 1fr;
            gap: .9rem;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card {
            padding: .72rem;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-work-thumb,
        body.bluecg-public-gallery-page .bluecg-public-work-media .bluecg-gallery-main {
            min-height: 12rem;
            aspect-ratio: 4 / 3;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-actions {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-work-expand {
            width: 100%;
            justify-content: center;
        }

        body.bluecg-public-gallery-page .bluecg-author-uid {
            grid-column: 1 / -1;
        }

        body.bluecg-public-gallery-page .bluecg-image-modal-frame {
            width: 100%;
            height: min(88dvh, 44rem);
            padding: 3rem .75rem 3.4rem;
        }
    }

    @media (max-width: 430px) {
        body.bluecg-public-gallery-page .bluecg-gallery-entry-actions,
        body.bluecg-public-gallery-page .bluecg-category-nav {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-gallery-entry-action,
        body.bluecg-public-gallery-page .bluecg-gallery-entry-state {
            min-height: 2.65rem;
        }
    }

    @media (prefers-reduced-motion: reduce) {
        body.bluecg-public-gallery-page .bluecg-public-work-card,
        body.bluecg-public-gallery-page .bluecg-public-work-card *,
        body.bluecg-public-gallery-page .bluecg-image-modal * {
            animation-duration: .01ms !important;
            transition-duration: .01ms !important;
            scroll-behavior: auto !important;
        }
    }
}

/* Public gallery masonry and detail refinement */
@media all {
    body.bluecg-public-gallery-page .bluecg-public-showcase-grid {
        grid-template-columns: repeat(auto-fill, minmax(min(100%, 18.5rem), 1fr));
        align-items: start;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card {
        align-self: start;
        padding: .82rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card:not(.is-expanded) .bluecg-public-work-media .bluecg-work-thumb,
    body.bluecg-public-gallery-page .bluecg-public-work-card:not(.is-expanded) .bluecg-public-work-media .bluecg-gallery-main {
        min-height: clamp(11.5rem, 19vw, 15.5rem);
        aspect-ratio: 4 / 3;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-stats {
        display: flex;
        flex-wrap: wrap;
        gap: .38rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-stats span {
        display: inline-flex;
        align-items: center;
        min-height: 1.7rem;
        padding: .22rem .52rem;
        border: 1px solid rgba(36, 120, 117, .12);
        border-radius: 999px;
        background: rgba(255, 254, 249, .75);
        color: #675d53;
        font-size: .72rem;
        font-weight: 860;
        line-height: 1.2;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-preview {
        display: -webkit-box;
        margin: 0;
        overflow: hidden;
        color: #574d44;
        font-size: .86rem;
        font-weight: 720;
        line-height: 1.58;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-preview {
        display: none;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-gallery {
        position: sticky;
        top: .75rem;
        align-self: start;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-gallery-main img,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-thumb > img {
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-stats {
        padding: .55rem .6rem;
        border: 1px solid rgba(36, 120, 117, .12);
        border-radius: .85rem;
        background: rgba(255, 254, 249, .72);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
        display: grid;
    }

    @media (min-width: 1180px) {
        body.bluecg-public-gallery-page .bluecg-public-showcase-grid {
            grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr));
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded {
            grid-template-columns: minmax(0, 1.36fr) minmax(25rem, .9fr);
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main {
            min-height: clamp(24rem, 34vw, 36rem);
        }
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) {
        align-items: start;
        overflow: hidden;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-media,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-body {
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-media {
        position: relative;
        z-index: 0;
        overflow: hidden;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-body {
        position: relative;
        z-index: 1;
        padding: .22rem;
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .92), rgba(248, 253, 251, .82));
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-media .bluecg-work-gallery,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-media .bluecg-work-thumb,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-public-work-media .bluecg-work-youtube {
        position: static;
        top: auto;
        width: 100%;
        max-width: 100%;
        min-height: 0;
        aspect-ratio: auto;
        overflow: hidden;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-youtube-box,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-content-video {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-content-video {
        min-height: 0;
        max-height: none;
        aspect-ratio: 16 / 9;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-content-video iframe {
        display: block;
        width: 100%;
        height: 100%;
    }

    @media (min-width: 920px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) {
            grid-template-columns: minmax(0, 1fr) minmax(22rem, .88fr);
        }
    }

    @media (min-width: 1180px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) {
            grid-template-columns: minmax(0, 1.08fr) minmax(24rem, .88fr);
        }
    }

    @media (max-width: 920px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-gallery {
            position: static;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) .bluecg-content-video {
            min-height: 0;
        }
    }
}

/* Public gallery final image and comment override 2026-06-29 */
@media all {
    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state {
        border-color: rgba(36, 120, 117, .24);
        background:
            linear-gradient(180deg, rgba(237, 253, 249, .98), rgba(230, 248, 244, .88));
        color: #1f7774;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state::before {
        background: linear-gradient(90deg, #247872, #54b3a9);
        opacity: .82;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state.is-status {
        cursor: default;
    }

    body.bluecg-public-gallery-page .bluecg-event-action-chip.comment-state.is-status:hover {
        transform: none;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded:has(.bluecg-work-youtube) {
        grid-column: 1 / -1;
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: 1.05rem;
        overflow: visible;
        padding: clamp(.85rem, 1.6vw, 1.2rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-body {
        min-width: 0;
        width: 100%;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-gallery {
        position: static;
        top: auto;
        width: 100%;
        max-width: 100%;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb:not(.bluecg-work-youtube):not(.is-empty) {
        min-height: 0;
        max-height: none;
        aspect-ratio: auto;
        padding: clamp(.75rem, 2vw, 1rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main {
        border-color: rgba(36, 120, 117, .24);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .96), rgba(247, 251, 248, .88)),
            repeating-linear-gradient(45deg, rgba(36, 120, 117, .035) 0 .5rem, transparent .5rem 1rem);
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-main img,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-work-thumb > img {
        display: block;
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: min(72dvh, 52rem);
        margin: auto;
        object-fit: contain;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-media .bluecg-gallery-controls {
        margin-top: .62rem;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-body {
        padding: .18rem;
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .82), rgba(239, 250, 247, .52));
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
        display: grid;
        grid-template-columns: minmax(0, .9fr) minmax(22rem, 1.1fr);
        gap: .9rem;
        align-items: start;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-concept,
    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-links {
        grid-column: 1;
    }

    body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-comments {
        grid-column: 2;
        grid-row: 1 / span 2;
    }

    body.bluecg-public-gallery-page .bluecg-work-comments {
        gap: .9rem;
        padding: 1rem;
        border-color: rgba(36, 120, 117, .18);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .96), rgba(236, 250, 247, .82));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .75rem 1.55rem rgba(36, 120, 117, .08);
    }

    body.bluecg-public-gallery-page .bluecg-comments-head {
        padding-bottom: .65rem;
        border-bottom: 1px solid rgba(36, 120, 117, .12);
    }

    body.bluecg-public-gallery-page .bluecg-comments-head span {
        display: inline-flex;
        align-items: center;
        min-height: 1.75rem;
        padding: .18rem .52rem;
        border: 1px solid rgba(36, 120, 117, .16);
        border-radius: 999px;
        background: rgba(239, 253, 249, .82);
        color: #247872;
    }

    body.bluecg-public-gallery-page .bluecg-comment {
        border-color: rgba(36, 120, 117, .12);
        border-radius: .9rem;
        background:
            linear-gradient(180deg, rgba(255, 255, 253, .92), rgba(255, 250, 239, .78));
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, .74);
    }

    body.bluecg-public-gallery-page .bluecg-comment-empty,
    body.bluecg-public-gallery-page .bluecg-comment-more,
    body.bluecg-public-gallery-page .bluecg-comment-login {
        padding: .78rem .86rem;
        border: 1px dashed rgba(36, 120, 117, .22);
        border-radius: .86rem;
        background: rgba(255, 254, 249, .72);
    }

    body.bluecg-public-gallery-page .bluecg-comment-form {
        gap: .68rem;
        padding: .9rem;
        border: 1px solid rgba(36, 120, 117, .2);
        border-radius: 1rem;
        background:
            linear-gradient(180deg, rgba(237, 253, 249, .96), rgba(255, 254, 249, .88));
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, .82),
            0 .7rem 1.45rem rgba(36, 120, 117, .08);
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head {
        display: flex;
        align-items: center;
        gap: .65rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-avatar {
        display: grid;
        place-items: center;
        flex: 0 0 auto;
        width: 2.35rem;
        height: 2.35rem;
        border: 1px solid rgba(36, 120, 117, .22);
        border-radius: .8rem;
        background:
            linear-gradient(180deg, rgba(57, 178, 168, .98), rgba(31, 119, 116, .96));
        color: #fffefa;
        font-size: .9rem;
        font-weight: 950;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head > div {
        display: grid;
        gap: .12rem;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head strong {
        color: #24211d;
        font-size: .9rem;
        font-weight: 950;
        line-height: 1.28;
        overflow-wrap: anywhere;
    }

    body.bluecg-public-gallery-page .bluecg-comment-form-head span:not(.bluecg-comment-avatar) {
        color: #247872;
        font-size: .75rem;
        font-weight: 900;
        line-height: 1.25;
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: .62rem;
        align-items: stretch;
        min-width: 0;
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose textarea {
        min-height: 5rem;
        border-color: rgba(36, 120, 117, .22);
        background: rgba(255, 255, 253, .96);
    }

    body.bluecg-public-gallery-page .bluecg-comment-compose .bluecg-button {
        align-self: stretch;
        min-width: 7.4rem;
        width: auto;
        margin: 0;
    }

    @media (max-width: 920px) {
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-public-work-details {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-concept,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-showcase-links,
        body.bluecg-public-gallery-page .bluecg-public-work-card.is-expanded .bluecg-work-comments {
            grid-column: 1;
            grid-row: auto;
        }
    }

    @media (max-width: 640px) {
        body.bluecg-public-gallery-page .bluecg-comment-compose {
            grid-template-columns: 1fr;
        }

        body.bluecg-public-gallery-page .bluecg-comment-compose .bluecg-button {
            width: 100%;
            min-height: 2.65rem;
        }
    }
}
