    .gallery-shell {
        position: relative;
        width: 100%;
        padding: 1.5rem 0 2rem;
        overflow: clip;
    }
    .gallery-shell::before {
        content: "";
        position: absolute;
        inset: 0;
        background:
            radial-gradient(circle at top left, rgba(34, 197, 94, 0.16), transparent 30%),
            radial-gradient(circle at top right, rgba(59, 130, 246, 0.15), transparent 28%),
            linear-gradient(180deg, rgba(248, 250, 252, 0.96), rgba(241, 245, 249, 0.88));
        pointer-events: none;
    }
    .gallery-shell::after {
        content: "";
        position: absolute;
        inset: auto 0 0 0;
        height: 220px;
        background: linear-gradient(180deg, rgba(255,255,255,0), rgba(226,232,240,0.34));
        pointer-events: none;
    }
    .gallery-shell-inner {
        position: relative;
        z-index: 1;
        width: min(1680px, calc(100vw - 32px));
        max-width: min(1680px, calc(100vw - 32px));
        margin-inline: auto;
    }
    .gallery-layout {
        display: grid;
        grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.16fr);
        gap: 1.5rem;
        align-items: start;
    }
    .gallery-sidebar {
        min-width: 0;
    }
    .gallery-main {
        min-width: 0;
        width: 100%;
        max-width: 100%;
        display: grid;
        gap: 1.5rem;
    }
    .gallery-hero {
        position: relative;
        z-index: 1;
        background: rgba(255, 255, 255, 0.9);
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 24px;
        padding: 1.6rem;
        margin-bottom: 1.5rem;
        box-shadow: 0 20px 56px rgba(15, 23, 42, 0.08);
        backdrop-filter: blur(18px);
    }
    .gallery-kicker {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 0.45rem 0.82rem;
        border-radius: 999px;
        border: 1px solid rgba(148, 163, 184, 0.14);
        background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(239, 246, 255, 0.82));
        color: #1e3a8a;
        font-size: 0.78rem;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        margin-bottom: 0.9rem;
        text-decoration: none;
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.68), 0 10px 24px rgba(15, 23, 42, 0.06);
        transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
    }
    .gallery-kicker:hover,
    .gallery-kicker:focus-visible {
        color: #0f172a;
        text-decoration: none;
        border-color: rgba(37, 99, 235, 0.24);
        background: linear-gradient(135deg, rgba(219, 234, 254, 0.96), rgba(224, 242, 254, 0.9));
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.76), 0 14px 28px rgba(37, 99, 235, 0.12);
        transform: translateY(-1px);
    }
    .gallery-kicker-logo {
        width: 24px;
        height: 24px;
        min-width: 24px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 8px;
        background: linear-gradient(135deg, #1d4ed8, #0ea5e9);
        color: #fff;
        box-shadow: 0 10px 18px rgba(37, 99, 235, 0.24);
        font-size: 0.72rem;
        font-weight: 900;
    }
    .gallery-kicker-copy {
        display: inline-flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 0.3rem;
    }
    .gallery-kicker-copy strong {
        font-weight: 900;
    }
    .gallery-kicker-copy span {
        color: #475569;
    }
    .gallery-hero .display-5 {
        text-align: center;
    }
    .gallery-meta-bar {
        display: flex;
        flex-wrap: wrap;
        gap: 0.65rem;
        margin: 1rem 0 1.2rem;
    }
    .gallery-pill {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 0.55rem 0.85rem;
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.05);
        font-size: 0.86rem;
        font-weight: 600;
    }
    .gallery-search {
        min-width: min(280px, 100%);
        flex: 0 1 280px;
    }
    .gallery-search.form-floating {
        position: relative;
    }
    .gallery-search .form-control {
        min-height: 54px;
        height: 54px;
        border-radius: 999px;
        border-color: rgba(148, 163, 184, 0.18);
        background: linear-gradient(135deg, rgba(255,255,255,0.96), rgba(248,250,252,0.92));
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.72);
        padding: 1.55rem 1rem 0.5rem;
    }
    .gallery-search .form-control:focus {
        border-color: rgba(37, 99, 235, 0.28);
        box-shadow: 0 0 0 0.22rem rgba(37, 99, 235, 0.12);
    }
    .gallery-search.form-floating > label {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        left: 0.2rem;
        right: 0.2rem;
        padding: 0.88rem 0.8rem;
        color: #64748b;
        font-weight: 700;
        letter-spacing: 0.01em;
    }
    .gallery-search.form-floating > label i {
        color: #2563eb;
        font-size: 0.92rem;
    }
    .gallery-search.form-floating > .form-control:focus ~ label,
    .gallery-search.form-floating > .form-control:not(:placeholder-shown) ~ label {
        color: #1d4ed8;
    }
    .gallery-description {
        max-width: 860px;
        position: relative;
        padding: 1.2rem 1.3rem;
        border-radius: 22px;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.96));
        border: 1px solid rgba(148, 163, 184, 0.18);
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.55), 0 16px 34px rgba(15, 23, 42, 0.05);
        color: #334155;
        line-height: 1.85;
    }
    .gallery-panel {
        position: relative;
        z-index: 1;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        padding: 1.2rem;
        border-radius: 24px;
        background: rgba(255, 255, 255, 0.92);
        border: 1px solid rgba(148, 163, 184, 0.16);
        box-shadow: 0 20px 52px rgba(15, 23, 42, 0.08);
        backdrop-filter: blur(18px);
        overflow: hidden;
    }
    .gallery-panel-back {
        position: absolute;
        top: 1.2rem;
        right: 1.2rem;
        z-index: 3;
    }
    .gallery-panel-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 1rem;
        flex-wrap: wrap;
        margin-bottom: 1rem;
        padding-right: 0;
    }
    .gallery-panel-head.has-back-action {
        padding-top: 4rem;
    }
    .gallery-panel-head-copy {
        flex: 1 1 320px;
        min-width: 0;
        max-width: calc(100% - 360px);
    }
    .gallery-panel-kicker {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 0.4rem 0.78rem;
        border-radius: 999px;
        background: rgba(37, 99, 235, 0.08);
        color: #1d4ed8;
        font-size: 0.78rem;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
    }
    .gallery-panel-title {
        margin: 0.8rem 0 0.15rem;
        color: #0f172a;
        font-size: 1.32rem;
        font-weight: 900;
        letter-spacing: -0.02em;
    }
    .gallery-panel-sub {
        flex: 1 0 100%;
        width: 100%;
        max-width: 100%;
        margin: 0;
        color: #64748b;
        line-height: 1.65;
        overflow-wrap: anywhere;
    }
    .gallery-panel-actions {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 0.65rem;
        flex-wrap: wrap;
    }
    .gallery-panel-actions-main {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 0.65rem;
        flex-wrap: nowrap;
    }
    .gallery-view-all-btn,
    .gallery-back-btn,
    .gallery-slideshow-btn {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.78rem 1rem;
        border-radius: 999px;
        border: 1px solid rgba(148, 163, 184, 0.2);
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.04), rgba(255, 255, 255, 0.92));
        color: #0f172a;
        font-weight: 800;
        text-decoration: none;
        white-space: nowrap;
        transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    }
    .gallery-view-all-btn:hover,
    .gallery-back-btn:hover,
    .gallery-slideshow-btn:hover {
        transform: translateY(-1px);
        border-color: rgba(37, 99, 235, 0.22);
        box-shadow: 0 18px 32px rgba(15, 23, 42, 0.08);
    }
    .gallery-slideshow-btn {
        border-color: rgba(37, 99, 235, 0.18);
        background: linear-gradient(135deg, #2563eb, #0ea5e9);
        color: #fff;
        box-shadow: 0 20px 36px rgba(37, 99, 235, 0.18);
    }
    .gallery-slideshow-btn:hover {
        border-color: rgba(125, 211, 252, 0.38);
        box-shadow: 0 22px 40px rgba(14, 165, 233, 0.24);
    }
    .gallery-next-card {
        position: relative;
        z-index: 1;
        padding: 1.25rem;
        border-radius: 24px;
        background: rgba(255, 255, 255, 0.92);
        border: 1px solid rgba(148, 163, 184, 0.16);
        box-shadow: 0 20px 52px rgba(15, 23, 42, 0.08);
        backdrop-filter: blur(18px);
    }
    .gallery-next-card-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 1rem;
        margin-bottom: 1rem;
        flex-wrap: wrap;
    }
    .gallery-next-card-title {
        margin: 0.55rem 0 0.12rem;
        color: #0f172a;
        font-size: 1.18rem;
        font-weight: 900;
        letter-spacing: -0.02em;
    }
    .gallery-next-card-sub {
        margin: 0;
        color: #64748b;
    }
    .gallery-next-list {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
        gap: 0.85rem;
    }
    .gallery-next-item {
        display: grid;
        grid-template-columns: 112px minmax(0, 1fr);
        gap: 0.78rem;
        align-items: center;
        padding: 0.72rem;
        border-radius: 20px;
        text-decoration: none;
        color: inherit;
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 252, 0.94));
        border: 1px solid rgba(148, 163, 184, 0.16);
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.56), 0 14px 30px rgba(15, 23, 42, 0.05);
        transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    }
    .gallery-next-item:hover {
        transform: translateY(-2px);
        border-color: rgba(37, 99, 235, 0.22);
        box-shadow: 0 20px 36px rgba(15, 23, 42, 0.08);
    }
    .gallery-next-item.is-primary {
        background:
            radial-gradient(circle at top right, rgba(14, 165, 233, 0.12), transparent 34%),
            linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(239, 246, 255, 0.94));
    }
    .gallery-next-media {
        position: relative;
        min-height: 88px;
        border-radius: 16px;
        overflow: hidden;
        background: linear-gradient(135deg, #dbeafe, #e2e8f0);
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
    }
    .gallery-next-item.is-primary .gallery-next-media {
        min-height: 88px;
    }
    .gallery-next-media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }
    .gallery-next-badge {
        position: absolute;
        top: 0.75rem;
        left: 0.75rem;
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        padding: 0.38rem 0.62rem;
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.72);
        color: #fff;
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 0.03em;
        backdrop-filter: blur(8px);
    }
    .gallery-next-content {
        min-width: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0.42rem;
    }
    .gallery-next-type {
        display: inline-flex;
        align-items: center;
        gap: 0.38rem;
        width: fit-content;
        padding: 0.34rem 0.62rem;
        border-radius: 999px;
        background: rgba(37, 99, 235, 0.08);
        color: #1d4ed8;
        font-size: 0.74rem;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
    }
    .gallery-next-item h3,
    .gallery-next-item h4 {
        margin: 0;
        color: #0f172a;
        font-weight: 900;
        letter-spacing: -0.02em;
        line-height: 1.16;
    }
    .gallery-next-item h3 {
        font-size: 1rem;
    }
    .gallery-next-item h4 {
        font-size: 0.96rem;
    }
    .gallery-next-summary {
        margin: 0;
        color: #475569;
        line-height: 1.5;
        font-size: 0.88rem;
    }
    .gallery-next-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    .gallery-next-pill {
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        padding: 0.44rem 0.7rem;
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.05);
        color: #334155;
        font-size: 0.78rem;
        font-weight: 700;
    }
    .gallery-next-arrow {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        color: #0f172a;
        font-size: 0.8rem;
        font-weight: 800;
    }
    .gallery-next-arrow i {
        color: #2563eb;
    }
    .gallery-glide,
    .gallery-preview-strip {
        position: relative;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        overflow: hidden;
        border-radius: 26px;
    }
    .gallery-preview-stage {
        position: relative;
        margin-bottom: 1rem;
    }
    .gallery-preview-feature {
        cursor: pointer;
    }
    .gallery-preview-stage-arrow {
        position: absolute;
        top: 50%;
        z-index: 3;
        width: 52px;
        height: 52px;
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 20px;
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.84), rgba(30, 41, 59, 0.72));
        color: #fff;
        box-shadow: 0 20px 42px rgba(2, 6, 23, 0.22);
        transform: translateY(-50%);
        transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    }
    .gallery-preview-stage-arrow:hover {
        transform: translateY(-50%) scale(1.04);
        background: linear-gradient(135deg, rgba(14, 165, 233, 0.92), rgba(37, 99, 235, 0.88));
        box-shadow: 0 24px 50px rgba(14, 165, 233, 0.22);
    }
    .gallery-preview-stage-arrow.prev {
        left: 1rem;
    }
    .gallery-preview-stage-arrow.next {
        right: 1rem;
    }
    .gallery-preview-thumb {
        position: relative;
        display: block;
        width: 100%;
        height: 110px;
        padding: 0;
        overflow: hidden;
        border: 0;
        border-radius: 18px;
        background: rgba(15, 23, 42, 0.08);
        box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.14);
        transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
        opacity: 0.72;
    }
    .gallery-preview-thumb::after {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(100deg, rgba(226, 232, 240, 0.72) 20%, rgba(248, 250, 252, 0.94) 38%, rgba(226, 232, 240, 0.72) 56%);
        background-size: 220% 100%;
        animation: gallery-thumb-loading 1.15s linear infinite;
        pointer-events: none;
        transition: opacity 0.16s ease;
    }
    .gallery-preview-thumb.is-loaded::after {
        opacity: 0;
    }
    @keyframes gallery-thumb-loading {
        to { background-position-x: -220%; }
    }
    .gallery-preview-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        opacity: 0;
        transition: opacity 0.16s ease;
    }
    .gallery-preview-thumb.is-loaded img {
        opacity: 1;
    }
    .gallery-preview-thumb.is-active {
        opacity: 1;
        box-shadow: inset 0 0 0 2px rgba(37, 99, 235, 0.88), 0 14px 28px rgba(15, 23, 42, 0.14);
    }
    .gallery-preview-thumb:hover {
        transform: translateY(-2px);
        opacity: 0.94;
    }
    @media (prefers-reduced-motion: reduce) {
        .gallery-preview-thumb::after {
            animation: none;
        }
    }
    .gallery-lightbox-sources {
        display: none;
    }
    .gallery-preview-strip {
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 0.3rem;
        scrollbar-width: thin;
        scrollbar-color: rgba(59, 130, 246, 0.35) transparent;
    }
    .gallery-preview-strip-track {
        display: flex;
        align-items: stretch;
        gap: 0.85rem;
        min-width: max-content;
    }
    .gallery-preview-strip-item {
        flex: 0 0 112px;
        width: 112px;
        min-width: 112px;
    }
    .gallery-preview-item {
        position: relative;
        display: block;
        width: 100%;
        max-width: 100%;
        min-height: 540px;
        height: 100%;
        overflow: hidden;
        border-radius: 26px;
        background: #0f172a;
        box-shadow: 0 24px 56px rgba(15, 23, 42, 0.18);
        isolation: isolate;
        text-decoration: none;
    }
    .gallery-preview-item::after {
        content: "";
        position: absolute;
        inset: auto 0 0 0;
        height: 45%;
        background: linear-gradient(180deg, rgba(2, 6, 23, 0), rgba(2, 6, 23, 0.72));
        z-index: 1;
        pointer-events: none;
    }
    .gallery-preview-item:hover .gallery-preview-img {
        transform: scale(1.02);
    }
    .gallery-preview-img {
        width: 100%;
        height: 100%;
        min-height: 540px;
        object-fit: cover;
        transition: transform 0.45s ease;
    }
    .gallery-preview-caption {
        position: absolute;
        right: 1rem;
        bottom: 1rem;
        z-index: 2;
        max-width: min(78%, 420px);
        padding: 0.85rem 0.95rem;
        border-radius: 20px 20px 8px 20px;
        background: linear-gradient(180deg, rgba(15, 23, 42, 0.14), rgba(15, 23, 42, 0.82));
        border: 1px solid rgba(255, 255, 255, 0.12);
        color: rgba(255,255,255,0.96);
        font-size: 0.9rem;
        font-weight: 700;
        line-height: 1.5;
        box-shadow: 0 18px 36px rgba(2, 6, 23, 0.18);
        backdrop-filter: blur(14px);
    }
    .gallery-preview-badge {
        position: absolute;
        top: 1rem;
        left: 1rem;
        z-index: 2;
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 0.5rem 0.78rem;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.92);
        color: #0f172a;
        font-size: 0.78rem;
        font-weight: 900;
        box-shadow: 0 14px 30px rgba(15, 23, 42, 0.14);
    }
    .gallery-glide-arrows {
        position: absolute;
        inset: 50% 0 auto 0;
        display: flex;
        justify-content: space-between;
        padding: 0 1rem;
        transform: translateY(-50%);
        pointer-events: none;
    }
    .gallery-glide-arrow {
        width: 54px;
        height: 54px;
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 20px;
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.84), rgba(30, 41, 59, 0.72));
        color: #fff;
        box-shadow: 0 22px 48px rgba(2, 6, 23, 0.24);
        pointer-events: auto;
        transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    }
    .gallery-glide-arrow:hover {
        transform: scale(1.04);
        background: linear-gradient(135deg, rgba(14, 165, 233, 0.92), rgba(37, 99, 235, 0.88));
        box-shadow: 0 26px 54px rgba(14, 165, 233, 0.24);
    }
    .gallery-glide-arrow i {
        pointer-events: none;
    }
    .gallery-glide-bullets {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-top: 1rem;
    }
    .gallery-glide-bullets .glide__bullet {
        width: 10px;
        height: 10px;
        margin: 0;
        border: 0;
        border-radius: 999px;
        background: rgba(148, 163, 184, 0.45);
        box-shadow: none;
        transition: transform 0.18s ease, background 0.18s ease;
    }
    .gallery-glide-bullets .glide__bullet--active {
        transform: scale(1.18);
        background: #2563eb;
    }
    .gallery-description > :first-child {
        margin-top: 0;
    }
    .gallery-description > :last-child {
        margin-bottom: 0;
    }
    .gallery-description h1,
    .gallery-description h2,
    .gallery-description h3,
    .gallery-description h4,
    .gallery-description h5,
    .gallery-description h6 {
        color: #0f172a;
        font-weight: 900;
        line-height: 1.18;
        letter-spacing: -0.02em;
        margin: 1.35rem 0 0.7rem;
    }
    .gallery-description h1 {
        font-size: clamp(1.9rem, 3.1vw, 2.5rem);
    }
    .gallery-description h2 {
        font-size: clamp(1.45rem, 2.4vw, 1.9rem);
    }
    .gallery-description h3 {
        font-size: clamp(1.22rem, 2vw, 1.5rem);
    }
    .gallery-description p,
    .gallery-description ul,
    .gallery-description ol,
    .gallery-description blockquote,
    .gallery-description table,
    .gallery-description figure,
    .gallery-description pre {
        margin: 0.95rem 0;
    }
    .gallery-description p {
        color: #334155;
    }
    .gallery-description strong {
        color: #0f172a;
        font-weight: 800;
    }
    .gallery-description .gallery-desc-bold {
        font-weight: 800;
        color: #0f172a;
    }
    .gallery-description .gallery-desc-italic {
        font-style: italic;
    }
    .gallery-description .gallery-desc-justify {
        text-align: justify;
    }
    .gallery-description .gallery-desc-float-left,
    .gallery-description .gallery-desc-float-right {
        max-width: min(320px, 48%);
        margin-bottom: 1rem;
    }
    .gallery-description .gallery-desc-float-left {
        float: left;
        margin-right: 1rem;
    }
    .gallery-description .gallery-desc-float-right {
        float: right;
        margin-left: 1rem;
    }
    .gallery-description .gallery-desc-clear {
        clear: both;
    }
    .gallery-description a {
        display: inline-flex;
        align-items: center;
        gap: 0.4rem;
        padding: 0.18rem 0.05rem;
        color: #0f4fd6;
        font-weight: 800;
        text-decoration: none;
        border-bottom: 1px solid rgba(15, 79, 214, 0.18);
        transition: color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
    }
    .gallery-description a:hover {
        color: #0b3fae;
        border-color: rgba(11, 63, 174, 0.34);
        transform: translateY(-1px);
    }
    .gallery-description ul,
    .gallery-description ol {
        padding-left: 0;
        list-style: none;
        display: grid;
        gap: 0.7rem;
    }
    .gallery-description ul li,
    .gallery-description ol li {
        position: relative;
        padding-left: 1.35rem;
    }
    .gallery-description ul li::before,
    .gallery-description ol li::before {
        position: absolute;
        left: 0;
        top: 0.32rem;
        font-size: 0.82rem;
        font-weight: 900;
        color: var(--nex-primary, #0d6efd);
    }
    .gallery-description ul li::before {
        content: "\f111";
        font-family: "Font Awesome 6 Free";
    }
    .gallery-description ol {
        counter-reset: gallery-desc-ordered;
    }
    .gallery-description ol li {
        counter-increment: gallery-desc-ordered;
    }
    .gallery-description ol li::before {
        content: counter(gallery-desc-ordered) ".";
    }
    .gallery-description blockquote {
        padding: 1rem 1.1rem 1rem 1.2rem;
        border-left: 4px solid #2563eb;
        border-radius: 0 18px 18px 0;
        background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(14, 165, 233, 0.03));
        color: #0f172a;
        font-style: italic;
        box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.06);
    }
    .gallery-description hr {
        border: 0;
        height: 1px;
        margin: 1.2rem 0;
        background: linear-gradient(90deg, transparent, rgba(148, 163, 184, 0.65), transparent);
    }
    .gallery-description img {
        max-width: 100%;
        height: auto;
        display: block;
        border-radius: 18px;
        box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
        margin: 1rem 0;
        cursor: zoom-in;
        transition: transform 0.22s ease, box-shadow 0.22s ease;
    }
    .gallery-description img:hover {
        transform: translateY(-2px);
        box-shadow: 0 22px 48px rgba(15, 23, 42, 0.16);
    }
    .gallery-description figure {
        margin: 1.1rem 0;
    }
    .gallery-description figcaption {
        margin-top: 0.65rem;
        color: #64748b;
        font-size: 0.88rem;
        text-align: center;
    }
    .gallery-description table {
        width: 100%;
        overflow: hidden;
        border-collapse: separate;
        border-spacing: 0;
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 18px;
        background: rgba(255,255,255,0.94);
        box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
    }
    .gallery-description th,
    .gallery-description td {
        padding: 0.85rem 0.95rem;
        border-bottom: 1px solid rgba(148, 163, 184, 0.14);
        text-align: left;
        vertical-align: top;
    }
    .gallery-description th {
        background: rgba(15, 23, 42, 0.04);
        color: #0f172a;
        font-weight: 800;
    }
    .gallery-description tr:last-child td {
        border-bottom: 0;
    }
    .gallery-description pre,
    .gallery-description code {
        font-family: "Consolas", "Courier New", monospace;
    }
    .gallery-description pre {
        padding: 1rem 1.1rem;
        border-radius: 18px;
        background: #0f172a;
        color: #e2e8f0;
        overflow: auto;
        box-shadow: 0 18px 36px rgba(15, 23, 42, 0.16);
    }
    .gallery-description :not(pre) > code {
        padding: 0.18rem 0.45rem;
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.06);
        color: #0f172a;
        font-size: 0.92em;
    }
    .gallery-grid {
        column-count: 4;
        column-gap: 1.25rem;
        position: relative;
        z-index: 1;
    }
    .gallery-item {
        position: relative;
        overflow: hidden;
        border-radius: 18px;
        cursor: pointer;
        appearance: none;
        -webkit-appearance: none;
        border: 0;
        padding: 0;
        width: 100%;
        background: transparent;
        text-align: inherit;
        color: inherit;
        font: inherit;
        transition: transform 0.28s ease, box-shadow 0.28s ease;
        display: block;
        break-inside: avoid;
        margin-bottom: 1.25rem;
        box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
    }
    .gallery-item:hover {
        transform: translateY(-5px);
        box-shadow: 0 24px 50px rgba(15, 23, 42, 0.14);
    }
    .gallery-img {
        width: 100%;
        height: auto;
        display: block;
        object-fit: cover;
        transition: transform 0.5s ease;
    }
    .gallery-item:hover .gallery-img {
        transform: scale(1.04);
    }
    .glightbox-stage {
        position: relative;
        overflow: hidden;
        align-items: center;
        justify-content: center;
        text-align: center;
    }
    .glightbox-prev,
    .glightbox-next {
        top: 50%;
        width: 64px;
        height: 64px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 22px;
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.84), rgba(30, 41, 59, 0.72));
        color: rgba(255, 255, 255, 0.96);
        box-shadow: 0 22px 48px rgba(2, 6, 23, 0.28);
        backdrop-filter: blur(18px);
        transform: translateY(-50%);
        transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, border-color 0.22s ease;
    }
    .glightbox-prev::before,
    .glightbox-next::before {
        content: "";
        display: block;
        width: 14px;
        height: 14px;
        border-top: 3px solid currentColor;
        border-right: 3px solid currentColor;
        line-height: 1;
    }
    .glightbox-prev {
        left: 22px;
    }
    .glightbox-prev::before {
        transform: rotate(-135deg);
        margin-left: 6px;
    }
    .glightbox-next {
        right: 22px;
    }
    .glightbox-next::before {
        transform: rotate(45deg);
        margin-right: 6px;
    }
    .glightbox-prev:hover,
    .glightbox-next:hover {
        background: linear-gradient(135deg, rgba(14, 165, 233, 0.92), rgba(37, 99, 235, 0.88));
        border-color: rgba(125, 211, 252, 0.45);
        box-shadow: 0 28px 58px rgba(14, 165, 233, 0.24);
        transform: translateY(-50%) scale(1.04);
    }
    .glightbox-prev:focus-visible,
    .glightbox-next:focus-visible {
        outline: none;
        border-color: rgba(125, 211, 252, 0.68);
        box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.18), 0 24px 52px rgba(14, 165, 233, 0.24);
    }
    .glightbox-prev:active,
    .glightbox-next:active {
        transform: translateY(-50%) scale(0.98);
    }
    .glightbox-prev,
    .glightbox-next {
        font-size: 0;
    }
    .glightbox-stage > img:not(.gallery-lightbox-ghost) {
        flex: 0 1 auto;
        width: auto;
        max-width: min(100%, 1120px);
        max-height: min(62vh, calc(100vh - 270px));
        object-fit: contain;
        margin-inline: auto;
    }
    .glightbox-stage .glightbox-caption {
        position: absolute;
        z-index: 2;
        right: 0;
        bottom: 0;
        display: none;
        padding: 0.95rem 1rem 1rem;
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 24px 24px 8px 24px;
        background:
            linear-gradient(180deg, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.72)),
            radial-gradient(circle at top right, rgba(56, 189, 248, 0.18), transparent 44%);
        color: rgba(255, 255, 255, 0.96);
        font-size: 0.94rem;
        line-height: 1.55;
        font-weight: 600;
        text-align: left;
        box-shadow: 0 18px 34px rgba(2, 6, 23, 0.18);
        backdrop-filter: blur(12px) saturate(1.1);
        pointer-events: none;
        overflow: hidden;
    }
    .glightbox-stage .glightbox-caption::before {
        content: "";
        position: absolute;
        inset: 0;
        background: linear-gradient(180deg, rgba(255,255,255,0.08), transparent 38%);
        pointer-events: none;
    }
    .glightbox-stage .glightbox-caption::after {
        content: "";
        position: absolute;
        inset: auto 0 0 auto;
        width: 88px;
        height: 2px;
        background: linear-gradient(90deg, rgba(125,211,252,0), rgba(125,211,252,0.9));
        opacity: 0.75;
    }
    .glightbox-stage .glightbox-caption.is-visible {
        display: block;
    }
    .glightbox-stage .gallery-lightbox-chrome {
        width: min(100%, 980px);
        display: grid;
        gap: 0.85rem;
        margin-top: 1rem;
        align-self: center;
        margin-inline: auto;
    }
    .gallery-lightbox-toolbar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.75rem;
        flex-wrap: wrap;
        padding: 0.8rem 0.95rem;
        border-radius: 20px;
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.82), rgba(30, 41, 59, 0.72));
        border: 1px solid rgba(148, 163, 184, 0.16);
        box-shadow: 0 22px 48px rgba(2, 6, 23, 0.28);
        backdrop-filter: blur(18px);
    }
    .gallery-lightbox-status {
        display: inline-flex;
        align-items: center;
        gap: 0.6rem;
        color: rgba(226, 232, 240, 0.92);
        font-size: 0.92rem;
        font-weight: 700;
    }
    .gallery-lightbox-status strong {
        color: #fff;
        font-size: 0.98rem;
        letter-spacing: 0.02em;
    }
    .gallery-lightbox-dot {
        width: 0.55rem;
        height: 0.55rem;
        border-radius: 999px;
        background: rgba(148, 163, 184, 0.68);
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4);
        transition: background 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
    }
    .gallery-lightbox-dot.is-playing {
        background: #22c55e;
        box-shadow: 0 0 0 0.45rem rgba(34, 197, 94, 0.14);
        transform: scale(1.05);
    }
    .gallery-lightbox-actions {
        display: flex;
        align-items: center;
        gap: 0.6rem;
        flex-wrap: wrap;
    }
    .gallery-lightbox-toggle {
        display: inline-flex;
        align-items: center;
        gap: 0.55rem;
        padding: 0.68rem 1rem;
        border: 0;
        border-radius: 999px;
        background: linear-gradient(135deg, #22c55e, #0ea5e9);
        color: #031525;
        font-weight: 800;
        box-shadow: 0 14px 28px rgba(14, 165, 233, 0.24);
        transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
    }
    .gallery-lightbox-toggle:hover {
        transform: translateY(-1px);
        box-shadow: 0 18px 34px rgba(14, 165, 233, 0.3);
        filter: brightness(1.02);
    }
    .gallery-lightbox-note {
        color: rgba(226, 232, 240, 0.72);
        font-size: 0.8rem;
        font-weight: 600;
    }
    .gallery-lightbox-thumbs {
        display: flex;
        gap: 0.7rem;
        padding-bottom: 0.25rem;
        overflow-x: auto;
        scrollbar-width: thin;
        cursor: grab;
        user-select: none;
        -webkit-user-select: none;
        touch-action: pan-x;
    }
    .gallery-lightbox-thumbs.is-dragging {
        cursor: grabbing;
    }
    .gallery-lightbox-thumbs::-webkit-scrollbar {
        height: 0.45rem;
    }
    .gallery-lightbox-thumbs::-webkit-scrollbar-thumb {
        border-radius: 999px;
        background: rgba(148, 163, 184, 0.34);
    }
    .gallery-lightbox-thumb {
        position: relative;
        width: 88px;
        min-width: 88px;
        height: 66px;
        padding: 0;
        overflow: hidden;
        border: 0;
        border-radius: 18px;
        background: rgba(15, 23, 42, 0.4);
        box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.14);
        transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.22s ease;
        opacity: 0.72;
    }
    .gallery-lightbox-thumb::after {
        content: "";
        position: absolute;
        inset: 0;
        border-radius: inherit;
        box-shadow: inset 0 0 0 2px transparent;
        transition: box-shadow 0.22s ease, background 0.22s ease;
    }
    .gallery-lightbox-thumb::before {
        content: attr(data-gallery-thumb-badge);
        position: absolute;
        top: 0.45rem;
        right: 0.45rem;
        min-width: 1.7rem;
        height: 1.7rem;
        padding: 0 0.5rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 999px;
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.88), rgba(30, 41, 59, 0.76));
        border: 1px solid rgba(255, 255, 255, 0.14);
        color: rgba(255, 255, 255, 0.98);
        font-size: 0.72rem;
        font-weight: 900;
        letter-spacing: 0.01em;
        box-shadow: 0 10px 22px rgba(2, 6, 23, 0.28);
        backdrop-filter: blur(10px);
        opacity: 0;
        transform: translateY(-2px) scale(0.94);
        transition: opacity 0.22s ease, transform 0.22s ease, background 0.22s ease, border-color 0.22s ease;
        pointer-events: none;
    }
    .gallery-lightbox-thumb:hover {
        transform: translateY(-2px);
        opacity: 0.95;
    }
    .gallery-lightbox-thumb.is-active {
        opacity: 1;
        box-shadow: 0 14px 28px rgba(15, 23, 42, 0.28);
    }
    .gallery-lightbox-thumb.is-active::after {
        box-shadow: inset 0 0 0 2px rgba(56, 189, 248, 0.95);
        background: linear-gradient(180deg, rgba(56, 189, 248, 0.14), rgba(34, 197, 94, 0.06));
    }
    .gallery-lightbox-thumb.is-active::before {
        background: linear-gradient(135deg, #0ea5e9, #2563eb);
        border-color: rgba(191, 219, 254, 0.48);
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    .gallery-lightbox-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: inherit;
        margin: 0;
        box-shadow: none;
    }
    .glightbox-stage .gallery-lightbox-ghost {
        position: absolute;
        inset: auto;
        margin: 0;
        pointer-events: none;
        z-index: 1;
        object-fit: cover;
        transform-origin: center center;
        transition: transform 0.46s cubic-bezier(.22, 1, .36, 1), opacity 0.46s ease, filter 0.46s ease;
        will-change: transform, opacity, filter;
    }
    .glightbox-stage.gallery-lightbox-morph-next .gallery-lightbox-ghost {
        transform: translateX(-8%) scale(0.92);
        opacity: 0;
        filter: blur(6px);
    }
    .glightbox-stage.gallery-lightbox-morph-prev .gallery-lightbox-ghost {
        transform: translateX(8%) scale(0.92);
        opacity: 0;
        filter: blur(6px);
    }
    .glightbox-stage img.gallery-lightbox-morph-enter {
        opacity: 0;
        filter: blur(10px);
        transform: scale(1.06) translateX(var(--gallery-lightbox-enter-x, 0));
        transition: transform 0.52s cubic-bezier(.22, 1, .36, 1), opacity 0.52s ease, filter 0.52s ease;
        will-change: transform, opacity, filter;
    }
    .glightbox-stage img.gallery-lightbox-morph-enter.gallery-lightbox-morph-enter-active {
        opacity: 1;
        filter: blur(0);
        transform: scale(1) translateX(0);
    }
    .glightbox-stage.gallery-lightbox-morph-next img.gallery-lightbox-morph-enter {
        --gallery-lightbox-enter-x: 8%;
    }
    .glightbox-stage.gallery-lightbox-morph-prev img.gallery-lightbox-morph-enter {
        --gallery-lightbox-enter-x: -8%;
    }
    .gallery-overlay {
        position: absolute;
        inset: 0;
        background: linear-gradient(180deg, rgba(2, 6, 23, 0.05), rgba(2, 6, 23, 0.72));
        opacity: 0;
        transition: opacity 0.3s ease;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-end;
        padding: 1rem;
        color: white;
    }
    .gallery-item:hover .gallery-overlay {
        opacity: 1;
    }
    .gallery-overlay i {
        font-size: 1.4rem;
        margin-bottom: 0.6rem;
        filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
    }
    .gallery-overlay span {
        font-size: 0.9rem;
        line-height: 1.45;
    }
    .gallery-empty-state {
        position: relative;
        z-index: 1;
        text-align: center;
        padding: 4rem 1.5rem;
        color: var(--nex-muted, #64748b);
        background: rgba(255, 255, 255, 0.82);
        border: 1px solid rgba(148, 163, 184, 0.16);
        border-radius: 22px;
    }
    .gallery-search-empty {
        position: relative;
        z-index: 1;
        display: none;
        text-align: center;
        padding: 3rem 1.5rem;
        margin-top: 1.25rem;
        color: #64748b;
        background: rgba(255, 255, 255, 0.86);
        border: 1px solid rgba(148, 163, 184, 0.16);
        border-radius: 22px;
        box-shadow: 0 18px 40px rgba(15, 23, 42, 0.06);
    }
    .gallery-search-empty.is-visible {
        display: block;
    }
    .gallery-search-empty strong {
        display: block;
        margin-bottom: 0.35rem;
        color: #0f172a;
        font-size: 1.02rem;
        font-weight: 800;
    }
    .gallery-engagement-strip {
        display: flex;
        flex-wrap: wrap;
        gap: 0.65rem;
        margin-bottom: 1.2rem;
    }
    .gallery-engagement-pill {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        padding: 0.55rem 0.85rem;
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.05);
        font-size: 0.86rem;
        font-weight: 700;
        color: #334155;
    }
    .media-engagement-card {
        position: relative;
        z-index: 1;
        margin-top: 1.5rem;
        padding: 1.3rem;
        border-radius: 24px;
        background: rgba(255,255,255,0.94);
        border: 1px solid rgba(148,163,184,0.16);
        box-shadow: 0 18px 44px rgba(15,23,42,0.08);
    }
    .media-engagement-head {
        display: flex;
        justify-content: space-between;
        gap: 1rem;
        flex-wrap: wrap;
        margin-bottom: 1rem;
    }
    .media-engagement-kicker,
    .media-reaction-btn,
    .media-reaction-stat,
    .media-member-pill {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        border-radius: 999px;
        font-weight: 800;
    }
    .media-engagement-kicker {
        padding: 0.4rem 0.78rem;
        background: rgba(37,99,235,0.08);
        color: #1d4ed8;
        font-size: 0.78rem;
        text-transform: uppercase;
        letter-spacing: .04em;
    }
    .media-engagement-head h2 { margin: 0.8rem 0 0.2rem; font-size: 1.35rem; font-weight: 900; color: #0f172a; }
    .media-engagement-head p { margin: 0; color: #64748b; }
    .media-reaction-row { display: flex; align-items: center; gap: 0.65rem; flex-wrap: wrap; }
    .media-reaction-btn,
    .media-reaction-stat,
    .media-member-pill {
        padding: 0.58rem 0.9rem;
        border: 1px solid rgba(148,163,184,0.18);
        background: rgba(15,23,42,0.04);
        color: #334155;
    }
    .media-reaction-btn.is-active { background: rgba(37,99,235,0.12); color: #1d4ed8; border-color: rgba(37,99,235,0.26); }
    .media-comment-auth,
    .media-comment-compose { margin-bottom: 1rem; }
    .media-comment-guest { display:flex; justify-content:space-between; gap:1rem; flex-wrap:wrap; padding:1rem; border-radius:18px; background:rgba(15,23,42,0.04); border:1px solid rgba(148,163,184,0.14); }
    .media-comment-compose textarea,
    .media-reply-box textarea { border-radius:18px; min-height:110px; }
    .media-compose-actions { display:flex; justify-content:space-between; gap:1rem; flex-wrap:wrap; align-items:center; margin-top:.75rem; }
    .media-compose-tools,
    .media-reply-actions { display:flex; align-items:center; gap:.75rem; flex-wrap:wrap; }
    .media-comments-list { display:grid; gap:1rem; }
    .media-comments-empty { padding:1rem; border-radius:18px; background:rgba(15,23,42,0.04); color:#64748b; }
    .media-comment-item,
    .media-comment-reply { padding:1rem; border-radius:20px; background:rgba(15,23,42,0.04); border:1px solid rgba(148,163,184,0.12); }
    .media-comment-shell { display:grid; grid-template-columns:46px minmax(0,1fr); gap:.9rem; align-items:start; }
    .media-comment-avatar { width:46px; height:46px; border-radius:999px; display:inline-flex; align-items:center; justify-content:center; background:var(--avatar-bg); color:#fff; font-size:.82rem; font-weight:900; letter-spacing:.14em; box-shadow:0 12px 24px rgba(15,23,42,.18); }
    .media-comment-main { min-width:0; }
    .media-comment-meta { display:flex; justify-content:flex-start; gap:1rem; flex-wrap:wrap; margin-bottom:.45rem; color:#64748b; font-size:.86rem; }
    .media-comment-identity { display:flex; align-items:center; gap:.7rem; flex-wrap:wrap; }
    .media-comment-identity strong { color:#0f172a; font-size:.96rem; }
    .media-comment-body { color:#334155; line-height:1.7; white-space:pre-wrap; overflow-wrap:anywhere; }
    .media-comment-actions { display:flex; align-items:center; gap:.55rem; flex-wrap:wrap; margin-top:.75rem; }
    .media-comment-reaction { display:inline-flex; align-items:center; gap:.4rem; border:1px solid rgba(148,163,184,.18); background:rgba(15,23,42,.04); color:#334155; border-radius:999px; padding:.42rem .72rem; font-weight:700; }
    .media-comment-reaction strong { font-size:.82rem; }
    .media-comment-reaction.is-active { background:rgba(37,99,235,.12); color:#1d4ed8; border-color:rgba(37,99,235,.26); }
    .media-comment-replies { display:grid; gap:.75rem; margin-top:.9rem; padding-left:1rem; border-left:2px solid rgba(148,163,184,0.18); }
    .media-reply-toggle,
    .media-thread-toggle { margin-top:0.65rem; border:0; background:none; color:#2563eb; font-weight:800; padding:0; }
    .media-reply-box { margin-top:.75rem; }
    .media-comment-thread-more { display:grid; gap:.75rem; margin-top:.65rem; }
    .media-emoji-wrap { position:relative; }
    .media-emoji-toggle { display:inline-flex; align-items:center; gap:.45rem; border:1px solid rgba(148,163,184,.18); background:rgba(15,23,42,.04); color:#334155; border-radius:999px; padding:.52rem .82rem; font-weight:700; }
    .media-emoji-panel { position:absolute; z-index:8; left:0; top:calc(100% + .55rem); width:min(320px, calc(100vw - 48px)); border-radius:18px; border:1px solid rgba(148,163,184,.18); background:rgba(255,255,255,.98); box-shadow:0 20px 45px rgba(15,23,42,.18); padding:.85rem; }
    .media-emoji-search { display:flex; align-items:center; gap:.65rem; border-radius:14px; padding:.65rem .8rem; background:rgba(15,23,42,.04); border:1px solid rgba(148,163,184,.14); margin-bottom:.75rem; color:#64748b; }
    .media-emoji-grid { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:.55rem; }
    .media-emoji-option { border:1px solid rgba(148,163,184,.14); background:rgba(15,23,42,.04); border-radius:14px; padding:.7rem .4rem; display:grid; gap:.3rem; place-items:center; color:#334155; font-weight:700; }
    .media-emoji-option i { font-size:1rem; color:#2563eb; }
    .media-emoji-option span:last-child { font-size:1.05rem; line-height:1; }
    [data-theme="dark"] .gallery-hero,
    [data-theme="dark"] .gallery-empty-state,
    [data-theme="dark"] .media-engagement-card,
    [data-theme="dark"] .media-comment-item,
    [data-theme="dark"] .media-comment-reply,
    [data-theme="dark"] .media-comments-empty,
    [data-theme="dark"] .media-comment-guest,
    [data-theme="dark"] .media-reaction-btn,
    [data-theme="dark"] .media-reaction-stat,
    [data-theme="dark"] .media-member-pill,
    [data-theme="dark"] .media-emoji-toggle,
    [data-theme="dark"] .media-emoji-panel,
    [data-theme="dark"] .media-emoji-search,
    [data-theme="dark"] .media-emoji-option,
    [data-theme="dark"] .media-comment-reaction {
        background: rgba(15, 23, 42, 0.88);
        border-color: rgba(148, 163, 184, 0.16);
        color: #fff;
    }
    [data-theme="dark"] .gallery-description {
        background: linear-gradient(135deg, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.82));
        border-color: rgba(148, 163, 184, 0.16);
        color: #cbd5e1;
        box-shadow: inset 0 1px 0 rgba(255,255,255,0.04), 0 18px 36px rgba(2, 6, 23, 0.28);
    }
    [data-theme="dark"] .gallery-description h1,
    [data-theme="dark"] .gallery-description h2,
    [data-theme="dark"] .gallery-description h3,
    [data-theme="dark"] .gallery-description h4,
    [data-theme="dark"] .gallery-description h5,
    [data-theme="dark"] .gallery-description h6,
    [data-theme="dark"] .gallery-description strong,
    [data-theme="dark"] .gallery-description .gallery-desc-bold {
        color: #f8fafc;
    }
    [data-theme="dark"] .gallery-description p,
    [data-theme="dark"] .gallery-description li,
    [data-theme="dark"] .gallery-description td,
    [data-theme="dark"] .gallery-description th {
        color: #cbd5e1;
    }
    [data-theme="dark"] .gallery-description a {
        color: #93c5fd;
        border-color: rgba(147, 197, 253, 0.25);
    }
    [data-theme="dark"] .gallery-description blockquote {
        background: linear-gradient(135deg, rgba(37, 99, 235, 0.2), rgba(14, 165, 233, 0.08));
        color: #e2e8f0;
    }
    [data-theme="dark"] .gallery-description table,
    [data-theme="dark"] .gallery-description th {
        background: rgba(15, 23, 42, 0.74);
        border-color: rgba(148, 163, 184, 0.16);
    }
    [data-theme="dark"] .gallery-description :not(pre) > code {
        background: rgba(148, 163, 184, 0.14);
        color: #f8fafc;
    }
    [data-theme="dark"] .media-comment-identity strong { color:#fff; }
    @media (max-width: 991.98px) {
        .gallery-layout {
            grid-template-columns: 1fr;
        }
        .gallery-hero {
            margin-bottom: 1.2rem;
        }
        .gallery-panel-head {
            padding-right: 0;
        }
        .gallery-panel-head.has-back-action {
            padding-top: 0;
        }
        .gallery-panel-head-copy {
            max-width: 100%;
        }
        .gallery-panel-back {
            position: static;
            margin-left: auto;
            margin-bottom: 0.75rem;
        }
        .gallery-panel-actions-main {
            flex-wrap: wrap;
        }
        .gallery-grid { column-count: 3; }
        .gallery-next-list {
            grid-template-columns: 1fr;
        }
        .gallery-next-media {
            min-height: 120px;
        }
        .gallery-preview-item,
        .gallery-preview-img {
            min-height: 460px;
        }
        .gallery-preview-thumb {
            height: 92px;
        }
        .glightbox-stage > img:not(.gallery-lightbox-ghost) {
            max-height: min(60vh, calc(100vh - 250px));
        }
    }
    @media (max-width: 767.98px) {
        .gallery-shell {
            padding-top: 1rem;
        }
        .gallery-shell-inner {
            width: min(100%, calc(100vw - 20px));
            max-width: min(100%, calc(100vw - 20px));
        }
        .gallery-hero,
        .gallery-panel,
        .gallery-next-card {
            border-radius: 20px;
        }
        .gallery-hero {
            padding: 1.1rem;
        }
        .gallery-hero .display-5 {
            font-size: clamp(1.6rem, 7vw, 2.2rem);
            line-height: 1.16;
        }
        .gallery-meta-bar,
        .gallery-panel-actions {
            gap: 0.55rem;
        }
        .gallery-pill,
        .gallery-panel-kicker,
        .gallery-next-type {
            font-size: 0.74rem;
        }
        .gallery-search {
            min-width: 100%;
            flex-basis: 100%;
        }
        .gallery-search .form-control {
            min-height: 50px;
            height: 50px;
        }
        .gallery-search.form-floating > label {
            padding: 0.72rem 0.8rem;
        }
        .gallery-description {
            padding: 1rem;
            border-radius: 18px;
            font-size: 0.96rem;
            line-height: 1.72;
            overflow-wrap: anywhere;
        }
        .gallery-panel-head {
            gap: 0.8rem;
        }
        .gallery-panel-title {
            font-size: 1.12rem;
            line-height: 1.2;
        }
        .gallery-panel-actions,
        .gallery-panel-actions-main {
            width: 100%;
        }
        .gallery-panel-actions-main {
            flex-wrap: wrap;
        }
        .gallery-view-all-btn,
        .gallery-back-btn,
        .gallery-slideshow-btn {
            justify-content: center;
        }
        .gallery-grid { column-count: 2; }
        .gallery-panel {
            padding: 1rem;
        }
        .gallery-preview-item,
        .gallery-preview-img {
            min-height: 360px;
            border-radius: 22px;
        }
        .gallery-preview-stage-arrow {
            width: 46px;
            height: 46px;
            border-radius: 16px;
        }
        .gallery-preview-caption {
            right: 0.75rem;
            bottom: 0.75rem;
            max-width: calc(100% - 1.5rem);
            padding: 0.75rem 0.8rem;
        }
        .gallery-preview-thumb {
            height: 76px;
            border-radius: 14px;
        }
        .gallery-next-item {
            grid-template-columns: 96px minmax(0, 1fr);
            gap: 0.7rem;
            padding: 0.65rem;
            border-radius: 18px;
        }
        .gallery-next-item h3,
        .gallery-next-item h4 {
            line-height: 1.2;
        }
        .gallery-search-empty {
            padding: 1rem;
            border-radius: 18px;
        }
        .glightbox-prev,
        .glightbox-next {
            width: 54px;
            height: 54px;
            border-radius: 18px;
        }
        .glightbox-prev {
            left: 14px;
        }
        .glightbox-next {
            right: 14px;
        }
        .glightbox-stage > img:not(.gallery-lightbox-ghost) {
            max-height: min(56vh, calc(100vh - 220px));
        }
        .glightbox-stage .gallery-lightbox-chrome {
            gap: 0.65rem;
        }
        .gallery-lightbox-toolbar {
            padding: 0.72rem 0.8rem;
        }
        .gallery-lightbox-thumbs {
            gap: 0.55rem;
        }
        .gallery-lightbox-thumb {
            width: 72px;
            min-width: 72px;
            height: 56px;
            border-radius: 16px;
        }
    }
    @media (max-width: 575.98px) {
        .gallery-grid { column-count: 1; }
        .gallery-hero {
            padding: 1rem;
        }
        .gallery-shell-inner {
            width: min(100%, calc(100vw - 14px));
            max-width: min(100%, calc(100vw - 14px));
        }
        .gallery-kicker,
        .gallery-pill {
            font-size: 0.72rem;
        }
        .gallery-meta-bar {
            margin-bottom: 1rem;
        }
        .gallery-panel {
            padding: 0.85rem;
        }
        .gallery-panel-title {
            font-size: 1rem;
        }
        .gallery-view-all-btn,
        .gallery-back-btn,
        .gallery-slideshow-btn {
            width: 100%;
        }
        .gallery-preview-item,
        .gallery-preview-img {
            min-height: 280px;
            border-radius: 18px;
        }
        .gallery-preview-stage-arrow {
            width: 42px;
            height: 42px;
            border-radius: 14px;
        }
        .gallery-preview-thumb {
            height: 68px;
            border-radius: 12px;
        }
        .gallery-next-item {
            grid-template-columns: 1fr;
        }
        .gallery-next-media {
            min-height: 168px;
            border-radius: 14px;
        }
        .gallery-description table,
        .gallery-description pre {
            display: block;
            overflow-x: auto;
        }
    }
