/**
 * Sticky Header Styles - Optimized
 * File: events/css/sticky-header.css
 * Description: Minimal CSS cho sticky header functionality
 */

/* Sticky Header Base Styles */
.sticky-header {
    position: relative; /* Mặc định không sticky */
    z-index: 9999 !important;
    transition: all 0.3s ease-in-out;
}

/* Sticky mode - Khi cần hiển thị sticky */
.sticky-header.sticky-mode {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Show state - Hiển thị sticky khi scroll lên */
.sticky-header.sticky-mode.show {
    transform: translateY(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Hide state - Ẩn sticky */
.sticky-header.sticky-mode.hide {
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Specific selectors for Bricks theme compatibility */
.brxe-section.sticky-header.sticky-mode.show,
body .brxe-section.sticky-header.sticky-mode.show,
html body .brxe-section.sticky-header.sticky-mode.show {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    transform: translateY(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
    z-index: 99999 !important;
    display: block !important;
}

.brxe-section.sticky-header.sticky-mode.hide,
body .brxe-section.sticky-header.sticky-mode.hide,
html body .brxe-section.sticky-header.sticky-mode.hide {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    z-index: 99999 !important;
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .sticky-header {
        transition: none;
    }
}
