:root {
    --gallery-primary: #0b2d4d;
    --gallery-secondary: #c62828;
    --gallery-ink: #243746;
    --gallery-muted: #607180;
    --gallery-line: #dbe4ea;
    --gallery-surface: #ffffff;
    --gallery-soft: #f4f8fa;
}

.gallery-page-body {
    background: var(--gallery-soft);
    color: var(--gallery-ink);
}

.gallery-page-body .navbar-bg {
    z-index: 1030;
}

.gallery-page-body .navbar .nav-link.active {
    color: var(--gallery-secondary);
}

.gallery-hero {
    position: relative;
    min-height: 320px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: url('../images/dr-kv-teja-reddy-inauguration.webp') center 42% / cover no-repeat;
}

.gallery-hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(11, 45, 77, 0.82);
}

.gallery-hero-content {
    position: relative;
    z-index: 1;
    max-width: 860px;
    padding: 74px 24px;
    color: #ffffff;
}

.gallery-eyebrow {
    margin: 0 0 12px;
    color: #f6caca;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.gallery-eyebrow i {
    margin-right: 7px;
}

.gallery-eyebrow-dark {
    color: var(--gallery-secondary);
}

.gallery-hero h1,
.gallery-section-heading h2,
.gallery-cta-content h2 {
    margin: 0;
    color: inherit;
    font-weight: 800;
    letter-spacing: 0;
}

.gallery-hero h1 {
    max-width: 660px;
    font-size: 3.6rem;
    line-height: 1.05;
}

.gallery-hero-content > p:last-child {
    max-width: 620px;
    margin: 18px 0 0;
    color: #e8f0f5;
    font-size: 1.08rem;
    line-height: 1.7;
}

.gallery-overview-section,
.gallery-content-section {
    padding: 70px 0;
}

.gallery-overview-section {
    background: var(--gallery-surface);
}

.gallery-section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 34px;
    margin-bottom: 34px;
}

.gallery-section-heading h2 {
    max-width: 660px;
    color: var(--gallery-primary);
    font-size: 2.55rem;
    line-height: 1.15;
}

.gallery-section-heading > p {
    max-width: 430px;
    margin: 0;
    color: var(--gallery-muted);
    line-height: 1.7;
}

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

.gallery-overview-item {
    display: flex;
    gap: 16px;
    min-height: 142px;
    padding: 25px;
    border: 1px solid var(--gallery-line);
    border-top: 3px solid var(--gallery-secondary);
    background: #ffffff;
}

.gallery-overview-icon {
    display: grid;
    flex: 0 0 44px;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    color: #ffffff;
    background: linear-gradient(135deg, var(--gallery-primary), var(--gallery-secondary));
}

.gallery-overview-item h3,
.gallery-card-copy h3 {
    margin: 0;
    color: var(--gallery-primary);
    font-size: 1.08rem;
    font-weight: 800;
    line-height: 1.3;
}

.gallery-overview-item p,
.gallery-card-copy p {
    margin: 8px 0 0;
    color: var(--gallery-muted);
    line-height: 1.55;
}

.gallery-content-section {
    background: var(--gallery-soft);
}

.gallery-section-heading-tight {
    margin-bottom: 21px;
}

.gallery-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-bottom: 28px;
}

.gallery-filter {
    min-height: 42px;
    padding: 9px 17px;
    border: 1px solid #b8c9d4;
    border-radius: 22px;
    color: var(--gallery-primary);
    background: #ffffff;
    font-weight: 700;
    transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.gallery-filter:hover,
.gallery-filter:focus-visible,
.gallery-filter.is-active {
    border-color: var(--gallery-primary);
    color: #ffffff;
    background: var(--gallery-primary);
}

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

.gallery-card {
    overflow: hidden;
    border: 1px solid var(--gallery-line);
    border-radius: 8px;
    background: var(--gallery-surface);
    box-shadow: 0 10px 24px rgba(11, 45, 77, 0.07);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.gallery-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 30px rgba(11, 45, 77, 0.13);
}

.gallery-card.is-hidden {
    display: none;
}

.gallery-open {
    position: relative;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    color: inherit;
    text-align: left;
    background: transparent;
}

.gallery-card-media {
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #dce5ea;
}

.gallery-card-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 220ms ease;
}

.gallery-card:hover .gallery-card-media img,
.gallery-open:focus-visible .gallery-card-media img {
    transform: scale(1.035);
}

.gallery-open-icon {
    position: absolute;
    right: 13px;
    bottom: 13px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    color: #ffffff;
    background: var(--gallery-secondary);
    box-shadow: 0 4px 12px rgba(11, 45, 77, 0.24);
}

.gallery-card-copy {
    min-height: 150px;
    padding: 21px 22px 24px;
}

.gallery-card-label,
.gallery-viewer-label {
    margin: 0 0 8px !important;
    color: var(--gallery-secondary) !important;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.gallery-cta-section {
    padding: 55px 0;
    color: #ffffff;
    background: var(--gallery-primary);
}

.gallery-cta-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.gallery-cta-content h2 {
    font-size: 2.55rem;
}

.gallery-cta-content > div:first-child > p:last-child {
    max-width: 610px;
    margin: 12px 0 0;
    color: #d6e2ea;
    line-height: 1.6;
}

.gallery-cta-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
}

.gallery-primary-action,
.gallery-light-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 11px 17px;
    border-radius: 5px;
    font-weight: 800;
    text-decoration: none;
}

.gallery-primary-action {
    color: #ffffff;
    background: var(--gallery-secondary);
}

.gallery-primary-action:hover,
.gallery-primary-action:focus-visible {
    color: #ffffff;
    background: #a82020;
}

.gallery-light-link {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.55);
}

.gallery-light-link:hover,
.gallery-light-link:focus-visible {
    color: var(--gallery-primary);
    background: #ffffff;
}

.gallery-viewer .modal-content {
    overflow: hidden;
    border: 0;
    border-radius: 8px;
    background: var(--gallery-primary);
}

.gallery-viewer .modal-header {
    align-items: flex-start;
    padding: 22px 26px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

.gallery-viewer .modal-title {
    color: #ffffff;
    font-size: 1.35rem;
    font-weight: 800;
}

.gallery-viewer-description {
    margin: 7px 0 0;
    color: #cbd9e2;
}

.gallery-viewer .modal-body {
    padding: 0;
    background: #071d31;
}

.gallery-viewer .carousel-item {
    aspect-ratio: 16 / 10;
    background: #071d31;
}

.gallery-viewer .carousel-item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.gallery-viewer .carousel-control-prev,
.gallery-viewer .carousel-control-next {
    width: 12%;
}

.gallery-viewer .carousel-control-prev-icon,
.gallery-viewer .carousel-control-next-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background-color: var(--gallery-secondary);
    background-size: 52%;
}

.gallery-page-body .footer-social-icons a {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    margin-right: 7px;
    border-radius: 50%;
    color: #ffffff;
    background: var(--gallery-secondary);
}

.gallery-page-body .footer-social-icons a:hover,
.gallery-page-body .footer-social-icons a:focus-visible {
    color: #ffffff;
    background: var(--gallery-primary);
}

@media (max-width: 991.98px) {
    .gallery-hero-content {
        padding: 62px 24px;
    }

    .gallery-overview-grid,
    .gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .gallery-section-heading,
    .gallery-cta-content {
        align-items: flex-start;
        flex-direction: column;
    }

    .gallery-cta-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 575.98px) {
    .gallery-hero {
        min-height: 290px;
    }

    .gallery-hero-content {
        padding: 54px 20px;
    }

    .gallery-hero h1 {
        font-size: 2.35rem;
    }

    .gallery-hero-content > p:last-child {
        font-size: 1rem;
    }

    .gallery-overview-section,
    .gallery-content-section {
        padding: 52px 0;
    }

    .gallery-overview-grid,
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .gallery-overview-item {
        min-height: 0;
    }

    .gallery-cta-section {
        padding: 46px 0;
    }

    .gallery-cta-actions,
    .gallery-primary-action,
    .gallery-light-link {
        width: 100%;
    }

    .gallery-viewer .modal-header {
        padding: 18px 18px 16px;
    }

    .gallery-viewer .modal-title {
        padding-right: 12px;
        font-size: 1.1rem;
    }

    .gallery-viewer-description {
        font-size: 0.88rem;
    }
}
