/* ============================================================
   newgalleryevent.css
   Standalone gallery CSS
   Does not depend on Bootstrap or the old gallery CSS.
   ============================================================ */

.ng-gallery-page,
.ng-gallery-page *,
.ng-page-banner,
.ng-page-banner * {
    box-sizing: border-box;
}

.ng-gallery-page {
    width: 100%;
    padding: 50px 0 70px;
    background: #f6f8fc;
}

.ng-container {
    width: calc(100% - 30px);
    max-width: 1180px;
    margin: 0 auto;
}

/* ---------------- Page Banner ---------------- */

.ng-page-banner {
    position: relative;
    overflow: hidden;
    padding: 62px 0 68px;
    background:
        linear-gradient(135deg, #182848 0%, #2b5876 55%, #4e4376 100%);
}

.ng-page-banner:before {
    content: "";
    position: absolute;
    width: 320px;
    height: 320px;
    right: -100px;
    top: -170px;
    border-radius: 50%;
    background: rgba(255,255,255,.08);
}

.ng-page-banner:after {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    left: -100px;
    bottom: -150px;
    border-radius: 50%;
    background: rgba(255,255,255,.06);
}

.ng-banner-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.ng-banner-line {
    width: 58px;
    height: 4px;
    margin: 0 auto 17px;
    border-radius: 10px;
    background: #ffffff;
}

.ng-page-title {
    margin: 0;
    padding: 0;
    color: #ffffff;
    font-size: clamp(27px, 4vw, 42px);
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: .4px;
}

.ng-page-subtitle {
    margin: 13px auto 0;
    max-width: 650px;
    color: rgba(255,255,255,.82);
    font-size: 15px;
    line-height: 1.7;
}

/* ---------------- Section Heading ---------------- */

.ng-section-heading {
    margin: 0 0 32px;
    text-align: center;
}

.ng-heading-line {
    display: block;
    width: 48px;
    height: 4px;
    margin: 0 auto 12px;
    border-radius: 10px;
    background: linear-gradient(90deg, #4f46e5, #06b6d4);
}

.ng-gallery-title {
    margin: 0;
    padding: 0;
    color: #182230;
    font-size: clamp(22px, 3vw, 30px);
    line-height: 1.35;
    font-weight: 700;
}

/* ---------------- Main Gallery ---------------- */

.ng-gallery-content {
    width: 100%;
}

.ng-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
}

.ng-gallery-card {
    min-width: 0;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #e7ebf2;
    /*border-radius: 18px; */
    box-shadow: 0 7px 25px rgba(15,23,42,.07);
    transition: transform .3s ease, box-shadow .3s ease;
}

.ng-gallery-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 18px 38px rgba(15,23,42,.14);
}

.ng-gallery-link {
    display: block;
    height: 100%;
    color: inherit;
    text-decoration: none !important;
}

.ng-gallery-image-wrap {
    position: relative;
    height: 235px;
    overflow: hidden;
    background: #e9edf4;
}

.ng-gallery-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .55s ease;
}

.ng-gallery-card:hover .ng-gallery-image {
    transform: scale(1.08);
}

.ng-image-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0) 45%,
        rgba(0,0,0,.35) 100%
    );
    pointer-events: none;
}

.ng-view-icon {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -35%) scale(.8);
    border: 1px solid rgba(255,255,255,.75);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(15,23,42,.58);
    font-size: 24px;
    opacity: 0;
    transition: all .3s ease;
}

.ng-gallery-card:hover .ng-view-icon {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.ng-gallery-body {
    padding: 21px 22px 24px;
}

.ng-gallery-badge {
    display: inline-block;
    margin-bottom: 9px;
    padding: 5px 10px;
    border-radius: 20px;
    color: #4338ca;
    background: #eef2ff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
}

.ng-gallery-card-title {
    margin: 0 0 10px;
    color: #172033;
    font-size: 19px;
    line-height: 1.4;
    font-weight: 700;
}

.ng-gallery-description {
    color: #687386;
    font-size: 14px;
    line-height: 1.7;
    text-align: justify;
    display: -webkit-box;
    -webkit-line-clamp: 10;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.ng-watch-button {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-top: 17px;
    padding: 10px 16px;
    border-radius: 25px;
    color: #ffffff;
    background: linear-gradient(135deg, #4f46e5, #0891b2);
    font-size: 13px;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(79,70,229,.22);
    transition: transform .25s ease, box-shadow .25s ease;
}

.ng-gallery-card:hover .ng-watch-button {
    transform: translateX(3px);
    box-shadow: 0 8px 19px rgba(79,70,229,.30);
}

.ng-watch-arrow {
    font-size: 16px;
    line-height: 1;
}

/* ---------------- Detail Gallery ---------------- */

.ng-detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.ng-detail-card {
    position: relative;
    min-width: 0;
    overflow: hidden;
    /*border-radius: 17px;*/
    background: #ffffff;
    border: 1px solid #e5e9f0;
    box-shadow: 0 7px 23px rgba(15,23,42,.08);
    cursor: pointer;
    outline: none;
    transition: transform .3s ease, box-shadow .3s ease;
}

.ng-detail-card:hover,
.ng-detail-card:focus {
    transform: translateY(-5px);
    box-shadow: 0 16px 34px rgba(15,23,42,.15);
}

.ng-detail-image-wrap {
    position: relative;
    height: 270px;
    overflow: hidden;
}

.ng-detail-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .55s ease;
}

.ng-detail-card:hover .ng-detail-image,
.ng-detail-card:focus .ng-detail-image {
    transform: scale(1.07);
}

.ng-detail-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 9px;
    background: rgba(15,23,42,.45);
    opacity: 0;
    transition: opacity .3s ease;
}

.ng-detail-card:hover .ng-detail-overlay,
.ng-detail-card:focus .ng-detail-overlay {
    opacity: 1;
}

.ng-zoom-icon {
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255,255,255,.7);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255,255,255,.14);
    font-size: 27px;
}

.ng-zoom-text {
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
}

/* ---------------- Empty ---------------- */

.ng-empty {
    width: 100%;
    padding: 55px 20px;
    text-align: center;
    border: 1px dashed #cbd5e1;
    border-radius: 18px;
    background: #ffffff;
}

.ng-empty-icon {
    width: 55px;
    height: 55px;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #4f46e5;
    background: #eef2ff;
    font-size: 25px;
}

.ng-empty h3 {
    margin: 0 0 7px;
    color: #273244;
    font-size: 19px;
}

.ng-empty p {
    margin: 0;
    color: #7a8494;
    font-size: 14px;
}

/* ---------------- Lightbox ---------------- */

body.ng-modal-open {
    overflow: hidden !important;
}

.ng-modal {
    position: fixed;
    z-index: 2147483000;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 25px;
    background: rgba(3,7,18,.94);
}

.ng-modal.ng-modal-show {
    display: flex;
    animation: ngModalFade .22s ease;
}

.ng-modal-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 95vw;
    max-height: 88vh;
}

.ng-modal-image {
    display: block;
    max-width: 94vw;
    max-height: 86vh;
    width: auto;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 20px 65px rgba(0,0,0,.5);
    animation: ngModalZoom .25s ease;
}

.ng-modal-close {
    position: absolute;
    z-index: 3;
    top: 18px;
    right: 22px;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255,255,255,.10);
    cursor: pointer;
    font-size: 30px;
    line-height: 1;
    transition: all .25s ease;
}

.ng-modal-close:hover {
    background: rgba(255,255,255,.22);
    transform: rotate(90deg);
}

.ng-modal-help {
    position: absolute;
    left: 50%;
    bottom: 17px;
    transform: translateX(-50%);
    color: rgba(255,255,255,.72);
    font-size: 12px;
    white-space: nowrap;
}

@keyframes ngModalFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes ngModalZoom {
    from {
        opacity: 0;
        transform: scale(.94);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ---------------- Responsive ---------------- */

@media (max-width: 991px) {
    .ng-gallery-grid,
    .ng-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ng-page-banner {
        padding: 50px 0 55px;
    }

    .ng-gallery-page {
        padding: 40px 0 55px;
    }
}

@media (max-width: 640px) {
    .ng-container {
        width: calc(100% - 24px);
    }

    .ng-gallery-grid,
    .ng-detail-grid {
        grid-template-columns: 1fr;
        gap: 19px;
    }

    .ng-page-banner {
        padding: 42px 0 46px;
    }

    .ng-gallery-page {
        padding: 32px 0 45px;
    }

    .ng-gallery-image-wrap {
        height: 225px;
    }

    .ng-detail-image-wrap {
        height: 260px;
    }

    .ng-gallery-body {
        padding: 18px 18px 21px;
    }

    .ng-gallery-card-title {
        font-size: 18px;
    }

    .ng-modal {
        padding: 10px;
    }

    .ng-modal-image {
        max-width: 96vw;
        max-height: 82vh;
    }

    .ng-modal-close {
        top: 10px;
        right: 10px;
    }

    .ng-modal-help {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ng-gallery-card,
    .ng-gallery-image,
    .ng-view-icon,
    .ng-detail-card,
    .ng-detail-image,
    .ng-modal,
    .ng-modal-image {
        transition: none !important;
        animation: none !important;
    }
}
