/* Front styles */
body{
    overflow-x: hidden;
    min-width: 320px;
}

.front-nav a {
    color: #495057;
    text-decoration: none;
    margin-right: 1rem;
}

.front-nav a:hover {
    color: #007bff;
}

/* Page Content Styles */
.page-content {
    width: 100%;
}

/* Preview Banner */
.alert.alert-warning {
    border-left: 4px solid #ffc107;
    background-color: #fff3cd;
    border-color: #ffeaa7;
}

.alert.alert-warning .bi-exclamation-triangle {
    color: #856404;
    font-size: 1.25rem;
}

.page-description {
    font-size: 1.125rem;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}


/* Page Blocks Styles */

.page-block {
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.page-block.block-paragraph {
    font-size: 1rem;
    line-height: 1.4;
}

.page-block.block-paragraph p {
    margin-bottom: 1rem;
}

.page-block.block-paragraph p:last-child {
    margin-bottom: 0;
}

/* Image Block Styles */
.page-block.block-image {
    text-align: center;
}

.page-block.block-image.align-left {
    text-align: left;
}

.page-block.block-image.align-right {
    text-align: right;
}

.page-block.block-image.align-center {
    text-align: center;
}

.page-block.block-image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.page-block.block-image figcaption {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #6c757d;
    font-style: italic;
}

/* List Block Styles */
.page-block.block-list ul,
.page-block.block-list ol {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.page-block.block-list li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.page-block.block-list li:last-child {
    margin-bottom: 0;
}

/* Spacer Block Styles */
.page-block.block-spacer {
    margin-bottom: 0;
}

/* Video Block Styles */
.page-block.block-video {
    margin-bottom: 2rem;
}

.video-block {
    max-width: 100%;
}

.video-wrapper {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background: #000;
}

.video-wrapper iframe,
.video-wrapper video {
    border: none;
    display: block;
}

.video-title {
    color: #212529;
    font-weight: 600;
    margin-bottom: 1rem;
}

.video-description {
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 0.5rem;
}

.video-description i {
    opacity: 0.7;
}

/* Responsive video containers */
@media (max-width: 768px) {
    .video-wrapper {
        height: auto !important;
        aspect-ratio: 16/9;
    }

    .video-wrapper video,
    .video-wrapper iframe {
        height: 100% !important;
    }
}

/* Gallery Block Styles */
.page-block.block-gallery {
    margin-bottom: 2rem;
}

.gallery-block {
    max-width: 100%;
}

/* Grid Gallery */
.gallery-block.gallery-grid .gallery-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-block.gallery-grid .gallery-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.gallery-block.gallery-grid .gallery-image {
    object-fit: cover;
    transition: opacity 0.3s ease;
}

.gallery-block.gallery-grid .gallery-image:hover {
    opacity: 0.9;
}

.gallery-block.gallery-grid .gallery-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0));
    color: white;
    padding: 1rem;
    font-size: 0.875rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.gallery-block.gallery-grid .gallery-item:hover .gallery-caption {
    transform: translateY(0);
}

/* Slideshow Gallery */
.gallery-block.gallery-slideshow {
    background: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
}

.gallery-block.gallery-slideshow .carousel-item img {
    height: 400px;
    object-fit: cover;
}

.gallery-block.gallery-slideshow .carousel-indicators {
    margin-bottom: 1rem;
}

.gallery-block.gallery-slideshow .carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin: 0 4px;
}

.gallery-block.gallery-slideshow .carousel-control-prev,
.gallery-block.gallery-slideshow .carousel-control-next {
    width: 5%;
    color: #212529;
}

.gallery-block.gallery-slideshow .carousel-control-prev-icon,
.gallery-block.gallery-slideshow .carousel-control-next-icon {
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    width: 40px;
    height: 40px;
}

/* Lightbox */
.lightbox-image {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 8px;
}

.lightbox-caption {
    max-width: 600px;
    margin: 0 auto;
}

/* Gallery Empty State */
.gallery-empty {
    text-align: center;
    padding: 3rem 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

/* Responsive Gallery */
@media (max-width: 768px) {
    .gallery-block.gallery-grid .col-6 {
        padding: 0.25rem;
    }

    .gallery-block.gallery-slideshow .carousel-item img {
        height: 250px;
    }

    .gallery-block.gallery-grid .gallery-caption {
        font-size: 0.75rem;
        padding: 0.75rem;
    }
}

@media (max-width: 576px) {
    .gallery-block.gallery-slideshow .carousel-control-prev,
    .gallery-block.gallery-slideshow .carousel-control-next {
        display: none;
    }
}

/* Button Block Styles */
.page-block.block-button {
    margin-bottom: 2rem;
}

.button-block {
    max-width: 100%;
}

.button-block .btn {
    transition: all 0.3s ease;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

.button-block .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.button-block .btn:active {
    transform: translateY(0);
}

.button-block .btn i {
    vertical-align: middle;
}

/* Button hover effects */
.button-block .btn-primary:hover {
    background-color: #0056b3;
    border-color: #004085;
}

.button-block .btn-success:hover {
    background-color: #198754;
    border-color: #146c43;
}

.button-block .btn-danger:hover {
    background-color: #dc3545;
    border-color: #b02a37;
}

.button-block .btn-warning:hover {
    background-color: #ffc107;
    border-color: #ffb300;
    color: #212529;
}

.button-block .btn-info:hover {
    background-color: #0dcaf0;
    border-color: #0aa2c0;
}

/* Button sizes */
.button-block .btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.button-block .btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.125rem;
}

/* Full width buttons */
.button-block .w-100 {
    display: block;
    width: 100%;
}

/* Button empty state */
.button-empty {
    text-align: center;
    padding: 2rem 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

/* Responsive button styles */
@media (max-width: 768px) {
    .button-block .btn-lg {
        padding: 0.625rem 1.25rem;
        font-size: 1rem;
    }

    /* Full width on mobile for better UX */
    .button-block .text-center .btn:not(.btn-sm) {
        min-width: 200px;
    }
}

@media (max-width: 576px) {
    .button-block .btn {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }

    .button-block .btn-lg {
        font-size: 1rem;
        padding: 0.625rem 1.25rem;
    }
}

/* Empty State */
.empty-page-content {
    text-align: center;
    padding: 3rem 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    margin: 2rem 0;
}

/* Page Footer */
.page-footer {
    text-align: center;
    color: #6c757d;
}


/* ========= Custom Header Menu Dropdown Styles ========= */

/* Base submenu styling */
.custom-submenu {
    list-style: none;
    margin: 0;
    padding: 0;
    background: white;
    border: 1px solid rgba(0,0,0,0.15);
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.15);
    overflow: hidden;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 260px;
    z-index: 1000;
    display: none;
}

.submenu-item {
    display: block;
    padding: 0.75rem 1.25rem;
    color: var(--bs-body-color, #212529);
    text-decoration: none;
    transition: all 0.2s ease;
    border: none;
    background: none;
}

.submenu-item:focus {
    background-color: var(--bs-primary, #0d6efd);
    color: white;
    text-decoration: none;
    transform: translateX(4px);
}

/* Hover effects only for hover-capable devices */
@media (hover: hover) and (pointer: fine) {
    .submenu-item:hover {
        background-color: transparent;
        color: white;
        text-decoration: none;
        transform: translateX(4px);
    }

    .submenu-item:hover i {
        opacity: 1;
    }
}

.submenu-item i {
    opacity: 0.8;
    transition: opacity 0.2s ease;
}

/* Desktop styles - only for devices with hover capability */
@media (min-width: 992px) and (hover: hover) and (pointer: fine) {
    .custom-dropdown {
        position: relative;
    }

    .custom-dropdown:hover .custom-submenu {
        display: block !important;
        animation: fadeInDown 0.2s ease-in-out;
    }

    .custom-dropdown-link {
        color: inherit;
        text-decoration: none;
        transition: color 0.2s ease;
    }

    .custom-dropdown-link:hover {
        color: var(--bs-primary, #0d6efd);
    }

    /* Hide mobile elements on desktop */
    .mobile-nav-item {
        display: none !important;
    }
}

/* Desktop without hover (touch laptops etc.) */
@media (min-width: 992px) and (hover: none) {
    .custom-dropdown {
        position: relative;
    }

    .custom-dropdown-link {
        color: inherit;
        text-decoration: none;
    }

    /* Hide mobile elements on desktop */
    .mobile-nav-item {
        display: none !important;
    }
}

/* Mobile styles */
@media (max-width: 991.98px) {
    .mobile-nav-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        padding: 0.5rem 0;
        margin: 0;
    }

    .mobile-main-link {
        flex: 1;
        color: inherit;
        text-decoration: none;
        padding: 0;
        margin: 0;
    }

    /* Only apply hover on hover-capable devices */
    @media (hover: hover) and (pointer: fine) {
        .mobile-main-link:hover {
            color: #fff;
        }
    }

    .mobile-toggle-btn {
        background: none;
        border: none;
        color: #fff;
        padding: 0.25rem;
        margin-right: 0.5rem;
        border-radius: 0.375rem;
        transition: all 0.2s ease;
        font-size: 0.875rem;
        line-height: 1;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        min-width: 32px;
        min-height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-toggle-btn:focus,
    .mobile-toggle-btn:active {
        color: #fff;
        background-color: rgba(0,0,0,0.1);
        outline: none;
    }

    /* Active state when menu is open */
    .mobile-toggle-btn.active {
        background-color: rgba(0,0,0,0.1);
        color: #fff;
    }

    /* Only apply hover on hover-capable devices */
    @media (hover: hover) and (pointer: fine) {
        .mobile-toggle-btn:hover {
            color: #fff;
            background-color: rgba(0,0,0,0.05);
        }
    }

    .mobile-toggle-btn i {
        transition: transform 0.2s ease;
        font-size: 0.875rem;
    }

    .mobile-toggle-btn.active i {
        transform: rotate(180deg);
    }

    .custom-submenu {
        position: static;
        width: 100%;
        border: none;
        box-shadow: none;
        border-radius: 0;
        background: rgba(0,0,0,0.02);
    }

    .custom-submenu.show {
        display: block;
    }

    .custom-submenu .submenu-item {
        padding: 0.625rem 1rem;
        font-size: 1rem;
    }

    /* Hide desktop elements on mobile */
    .custom-dropdown-link {
        display: none !important;
    }

    .custom-dropdown-link:hover {
        color: inherit !important;
    }
}

/* Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive nav adjustments */
@media (max-width: 991.98px) {
    .navbar-nav {
        padding-top: 0.5rem;
    }

    .nav-item:last-child .mobile-nav-item {
        border-bottom: none;
    }
}

/* ========= Gallery Masonry Styles ========= */

.gallery-wrapper{
  
}

.gallery-container{
    max-width: 1920px;
    margin: 0 auto;
}

.masonry-gallery {
    position: relative;
    width: 100%;
}

.masonry-item {
    padding: 10px; /* Half gap for total 15px between items */
    box-sizing: border-box;
    break-inside: avoid;
    position: relative;
    overflow: hidden;
}

.gallery-image {
    width: 100%;
    height: auto;
    cursor: pointer;
    transition: opacity 0.3s ease;
    display: block;
    max-width: 460px;
}

.gallery-image:hover {
    opacity: 0.95;
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0.4), transparent);
    color: white;
    padding: 1rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.masonry-item:hover .image-overlay {
    transform: translateY(0);
}

.overlay-title {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.2;
}

.overlay-description {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.3;
    opacity: 0.9;
}

/* Responsive adjustments for masonry */
@media (max-width: 1199px) {
    .masonry-item {
        padding: 8px; /* Smaller gap on tablets */
    }
}

@media (max-width: 767px) {
    .image-overlay {
        padding: 0.75rem;
    }

    .overlay-title {
        font-size: 0.875rem;
    }

    .overlay-description {
        font-size: 0.75rem;
    }
}

@media (max-width: 575px) {
    .image-overlay {
        padding: 0.5rem;
    }
}


/* Banner Block Styles */
.banner-block{
    height: 100%;
    margin-bottom: 20px;
}

@media (min-width: 768px){
    .banner-block {
        margin-bottom: 0;
    }
    
    .col-md-6:not(.section-full-text) .column-content{
        height: 100%;
    }
}

.banner-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
}

.banner-link:hover {
    color: inherit;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.banner-container {
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
    height: 100%;
}

.banner-link:hover .banner-container {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.banner-image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden !important;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.banner-link:hover .banner-image {
    transform: scale(1.05);
}

.banner-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4), transparent);
    color: white;
    padding: 2rem;
    transform: translateY(0);
    transition: transform 0.3s ease, padding 0.3s ease;
}

.banner-link:hover .banner-content {
    padding: 2.5rem 2rem;
}

.banner-title {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    font-weight: 600;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.banner-text {
    margin: 0 0 1rem 0;
    font-size: 1rem;
    line-height: 1.4;
    opacity: 0.95;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.banner-button {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.banner-link:hover .banner-button {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(5px);
}

.banner-button i {
    transition: transform 0.3s ease;
}

.banner-link:hover .banner-button i {
    transform: translateX(3px);
}

/* Responsive banner styles */
@media (max-width: 768px) {
    .banner-content {
        padding: 1.5rem;
    }

    .banner-link:hover .banner-content {
        padding: 1.75rem 1.5rem;
    }

    .banner-title {
        font-size: 1.25rem;
    }

    .banner-text {
        font-size: 0.9rem;
    }

    .banner-button {
        padding: 0.6rem 1.25rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .banner-content {
        padding: 1rem;
    }

    .banner-link:hover .banner-content {
        padding: 1.25rem 1rem;
    }

    .banner-title {
        font-size: 1.1rem;
    }

    .banner-text {
        font-size: 0.85rem;
    }

    .banner-button {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
}