/* ====================================================================
   GD GOENKA PUBLIC SCHOOL, PURNEA
   UNIFIED GALLERY HUB STYLES (Photo Gallery, Video Gallery, Goenkan in News)
   ==================================================================== */

section.gd-gallery-hub {
    padding: 52px 0 76px;
    background: #ffffff;
}

/* Left Sidebar Navigation */
.gd-nav-box {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    overflow: hidden;
    position: sticky;
    top: 105px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
}

.gd-nav-box-header {
    background: #1b3168;
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 15px 20px;
}

.gd-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.gd-nav-list li {
    border-bottom: 1px solid #f1f5f9;
}

.gd-nav-list li:last-child {
    border-bottom: none;
}

.gd-nav-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    font-size: 14.5px;
    font-weight: 600;
    color: #1e293b;
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.gd-nav-list a:hover {
    background: #f8fafc;
    color: #1b3168;
}

.gd-nav-list a.active {
    background: #faf6eb;
    color: #b59859;
    border-left-color: #b59859;
    font-weight: 700;
}

/* Right Main Content Area */
.gd-gallery-header {
    margin-bottom: 28px;
}

.gd-gallery-hub h2.gd-page-title {
    font-size: 30px;
    font-weight: 800;
    color: #1b3168;
    margin: 0 0 8px 0;
    line-height: 1.2;
}

.gd-gallery-hub p.gd-page-subtitle {
    font-size: 15px;
    line-height: 1.55;
    color: #475569;
    margin: 0;
}

.gd-gallery-hub h3.gd-section-label {
    font-size: 20px;
    font-weight: 800;
    color: #1b3168;
    margin: 0 0 22px 0;
}

/* Session Group Block */
.gd-session-block {
    margin-bottom: 42px;
}

.gd-session-block:last-child {
    margin-bottom: 0;
}

.gd-session-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 17px;
    font-weight: 700;
    color: #1b3168;
    padding-bottom: 9px;
    margin-bottom: 20px;
    border-bottom: 2px solid #c59b27;
}

.gd-session-meta {
    font-size: 12.5px;
    font-weight: 600;
    color: #64748b;
}

/* Album / Folder Card (Photo Gallery & Goenkan in News) */
.gd-album-card {
    display: block;
    text-decoration: none !important;
    color: inherit;
    height: 100%;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.gd-album-card:hover {
    transform: translateY(-4px);
}

.gd-album-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 6px;
    overflow: hidden;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.gd-album-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.gd-album-card:hover .gd-album-thumb img {
    transform: scale(1.06);
}

.gd-album-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(15, 23, 42, 0.78);
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    backdrop-filter: blur(4px);
}

.gd-album-info {
    padding: 10px 2px 4px;
}

.gd-album-title {
    font-size: 14px;
    font-weight: 700;
    color: #1b3168;
    margin: 0 0 3px 0;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s ease;
}

.gd-album-card:hover .gd-album-title {
    color: #b59859;
}

.gd-album-count {
    font-size: 12.5px;
    font-weight: 500;
    color: #64748b;
    display: block;
}

/* Inside Album View */
.gd-album-backbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding-bottom: 14px;
    margin-bottom: 24px;
    border-bottom: 2px solid #c59b27;
}

.gd-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 16px;
    border-radius: 8px;
    background: #f1f5f9;
    color: #1b3168;
    font-size: 13.5px;
    font-weight: 700;
    text-decoration: none;
    border: 1px solid #dbe3ef;
    transition: all 0.2s ease;
}

.gd-back-btn:hover {
    background: #1b3168;
    color: #ffffff;
    border-color: #1b3168;
}

.gd-album-detail-title {
    font-size: 22px;
    font-weight: 800;
    color: #1b3168;
    margin: 0 0 4px 0;
}

.gd-album-detail-meta {
    font-size: 13px;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.gd-session-pill {
    display: inline-block;
    background: #faf6eb;
    color: #9a7426;
    border: 1px solid #e7d9b8;
    font-size: 11.5px;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 999px;
}

/* Individual Photo Tile Inside Album */
.gd-photo-tile {
    display: block;
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: 8px;
    overflow: hidden;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    box-shadow: 0 3px 10px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.gd-photo-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
}

.gd-photo-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.gd-photo-tile:hover img {
    transform: scale(1.06);
}

.gd-photo-zoom-overlay {
    position: absolute;
    inset: 0;
    background: rgba(27, 49, 104, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.22s ease;
}

.gd-photo-tile:hover .gd-photo-zoom-overlay {
    opacity: 1;
}

.gd-photo-zoom-overlay span {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #ffffff;
    color: #1b3168;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* News Portrait-friendly option (cover still neat, full paper visible in lightbox) */
.gd-news-tile {
    aspect-ratio: 3 / 4;
    background: #f8fafc;
}

.gd-news-tile img {
    object-fit: cover;
    object-position: top center;
}

/* Video Card Styling */
.gd-video-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    text-decoration: none !important;
    color: inherit;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.gd-video-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.11);
    border-color: #cbd5e1;
}

.gd-video-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #0f172a;
    overflow: hidden;
}

.gd-video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease, opacity 0.3s ease;
}

.gd-video-card:hover .gd-video-thumb img {
    transform: scale(1.05);
    opacity: 0.88;
}

.gd-video-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(220, 38, 38, 0.92);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    padding-left: 3px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
    transition: transform 0.25s ease, background 0.25s ease;
}

.gd-video-card:hover .gd-video-play {
    transform: translate(-50%, -50%) scale(1.1);
    background: #dc2626;
}

.gd-video-body {
    padding: 14px 16px 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.gd-video-title {
    font-size: 14.5px;
    font-weight: 700;
    color: #1b3168;
    margin: 0 0 6px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gd-video-card:hover .gd-video-title {
    color: #b59859;
}

.gd-video-sub {
    font-size: 12px;
    color: #64748b;
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* Video Modal Player */
.gd-video-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.88);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(4px);
}

.gd-video-modal-backdrop.open {
    display: flex;
}

.gd-video-modal-box {
    width: 100%;
    max-width: 900px;
    background: #0f172a;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.gd-video-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: #1b3168;
    color: #ffffff;
}

.gd-video-modal-header h5 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 12px;
}

.gd-video-modal-close {
    border: none;
    background: rgba(255, 255, 255, 0.16);
    color: #ffffff;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    flex-shrink: 0;
    transition: background 0.2s ease;
}

.gd-video-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.gd-video-embed-wrap {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #000000;
}

.gd-video-embed-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Empty State */
.gd-empty-box {
    text-align: center;
    padding: 48px 20px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    color: #64748b;
}

.gd-empty-box i {
    font-size: 40px;
    color: #94a3b8;
    display: block;
    margin-bottom: 10px;
}

/* ====================================================================
   RESPONSIVE BREAKPOINTS
   ==================================================================== */
@media (max-width: 991px) {
    section.gd-gallery-hub {
        padding: 36px 0 56px;
    }
    .gd-nav-box {
        position: static;
        margin-bottom: 28px;
    }
    .gd-nav-list {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .gd-nav-list li {
        flex: 1 0 auto;
        border-bottom: none;
        border-right: 1px solid #f1f5f9;
    }
    .gd-nav-list li:last-child {
        border-right: none;
    }
    .gd-nav-list a {
        justify-content: center;
        padding: 12px 14px;
        font-size: 13.5px;
        white-space: nowrap;
        border-left: none;
        border-bottom: 3px solid transparent;
    }
    .gd-nav-list a.active {
        border-left-color: transparent;
        border-bottom-color: #b59859;
    }
}

@media (max-width: 767px) {
    section.gd-gallery-hub {
        padding: 26px 0 46px;
    }
    .gd-gallery-hub h2.gd-page-title {
        font-size: 24px;
    }
    .gd-gallery-hub p.gd-page-subtitle {
        font-size: 13.5px;
        line-height: 1.5;
    }
    .gd-gallery-hub h3.gd-section-label {
        font-size: 18px;
        margin-bottom: 16px;
    }
    .gd-session-heading {
        font-size: 15.5px;
        margin-bottom: 14px;
    }
    .gd-album-title {
        font-size: 13px;
    }
    .gd-album-count {
        font-size: 11.5px;
    }
    .gd-album-detail-title {
        font-size: 18px;
    }
    .gd-video-play {
        width: 48px;
        height: 48px;
        font-size: 20px;
    }
}

/* ====================================================================
   DIRECT GOENKAN IN NEWS GRID & PAGINATION STYLES
   ==================================================================== */
.gd-gallery-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #c59b27;
}

.gd-filter-pills {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.gd-filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none !important;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #334155;
    transition: all 0.2s ease;
}

.gd-filter-pill:hover {
    background: #f8fafc;
    border-color: #94a3b8;
    color: #1b3168;
    transform: translateY(-1px);
}

.gd-filter-pill.active {
    background: #1b3168;
    border-color: #1b3168;
    color: #ffffff !important;
    box-shadow: 0 3px 8px rgba(27, 49, 104, 0.22);
}

.gd-filter-pill .pill-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 1px 7px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
}

.gd-filter-pill.active .pill-badge {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.gd-btn-open-all {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 16px;
    border-radius: 8px;
    background: #faf6eb;
    color: #9a7426;
    border: 1px solid #e7d9b8;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none !important;
    cursor: pointer;
    transition: all 0.22s ease;
}

.gd-btn-open-all:hover {
    background: #9a7426;
    color: #ffffff !important;
    border-color: #9a7426;
    box-shadow: 0 4px 12px rgba(154, 116, 38, 0.25);
    transform: translateY(-1px);
}

/* Individual News Clipping Card */
.gd-news-card-link {
    display: block;
    text-decoration: none !important;
    color: inherit !important;
    height: 100%;
}

.gd-news-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.gd-news-card-link:hover .gd-news-card {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.12);
    border-color: #cbd5e1;
}

.gd-news-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    background: #f8fafc;
    overflow: hidden;
    border-bottom: 1px solid #f1f5f9;
}

.gd-news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.gd-news-card-link:hover .gd-news-thumb img {
    transform: scale(1.06);
}

.gd-news-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.08) 0%, rgba(15, 23, 42, 0.65) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.22s ease;
}

.gd-news-card-link:hover .gd-news-overlay {
    opacity: 1;
}

.gd-news-zoom-pill {
    background: #ffffff;
    color: #1b3168;
    font-size: 13px;
    font-weight: 700;
    padding: 8px 16px;
    border-radius: 999px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transform: translateY(6px);
    transition: transform 0.22s ease;
}

.gd-news-card-link:hover .gd-news-zoom-pill {
    transform: translateY(0);
}

.gd-news-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(27, 49, 104, 0.9);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 5px;
    backdrop-filter: blur(4px);
    letter-spacing: 0.3px;
}

.gd-news-index-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(15, 23, 42, 0.75);
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 5px;
    backdrop-filter: blur(4px);
}

.gd-news-body {
    padding: 14px 16px 14px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.gd-news-title {
    font-size: 14.5px;
    font-weight: 700;
    color: #1b3168;
    margin: 0 0 8px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s ease;
}

.gd-news-card-link:hover .gd-news-title {
    color: #b59859;
}

.gd-news-meta {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: #64748b;
    padding-top: 8px;
    border-top: 1px dashed #e2e8f0;
}

.gd-news-meta-date {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.gd-news-action-hint {
    font-weight: 600;
    color: #1b3168;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s ease;
}

.gd-news-card-link:hover .gd-news-action-hint {
    color: #b59859;
}

/* Clear Pagination Section */
.gd-pagination-container {
    margin-top: 36px;
    padding-top: 24px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

@media (min-width: 768px) {
    .gd-pagination-container {
        flex-direction: row;
        justify-content: space-between;
    }
}

.gd-pagination-summary {
    font-size: 13.5px;
    color: #64748b;
    font-weight: 500;
}

.gd-pagination-summary strong {
    color: #1b3168;
    font-weight: 700;
}

.gd-pagination-list {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
    justify-content: center;
}

.gd-page-item {
    display: inline-block;
}

.gd-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 11px;
    border-radius: 8px;
    font-size: 13.5px;
    font-weight: 600;
    color: #334155;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    text-decoration: none !important;
    transition: all 0.2s ease;
}

.gd-page-btn:hover {
    background: #faf6eb;
    color: #9a7426;
    border-color: #d4ba7d;
    transform: translateY(-1px);
}

.gd-page-btn.active {
    background: #1b3168;
    color: #ffffff !important;
    border-color: #1b3168;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(27, 49, 104, 0.25);
}

.gd-page-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
    background: #f8fafc;
    border-color: #e2e8f0;
    color: #94a3b8;
}

.gd-page-dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 38px;
    color: #94a3b8;
    font-weight: 700;
    font-size: 15px;
    user-select: none;
}

