/* Professional Scroll Indicator System - Application-Wide */

/* ===================================
   HIDE NATIVE SCROLLBARS
   =================================== */

/* Hide vertical scrollbars for main containers (they use indicators) */
.scroll-container,
.dashboard-content,
.sidebar-nav,
.main-content,
.detail-container {
    /* Firefox */
    scrollbar-width: none;
    /* IE/Edge */
    -ms-overflow-style: none;
}

/* Chrome/Safari/WebKit */
.scroll-container::-webkit-scrollbar,
.dashboard-content::-webkit-scrollbar,
.sidebar-nav::-webkit-scrollbar,
.main-content::-webkit-scrollbar,
.detail-container::-webkit-scrollbar {
    display: none;
}

/* Note: Horizontal scrollbars for grids are styled in grid.css and always visible */

/* ===================================
   SCROLL INDICATOR COMPONENTS
   =================================== */

/* Base scroll indicator styling - Subtle white circles */
.scroll-indicator {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.95);
    color: #4b5563;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s var(--ease-out);
    z-index: 1000;
    cursor: pointer;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.scroll-indicator:hover {
    background: rgba(255, 255, 255, 1);
    color: #4b5563;
    transform: translateX(-50%) scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Bottom scroll indicator */
.scroll-indicator-bottom {
    bottom: 24px;
    animation: bounce 2s infinite;
}

.scroll-indicator-bottom.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-indicator-bottom.scrolling {
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s var(--ease-in);
}

/* Top scroll indicator (when at bottom) */
.scroll-indicator-top {
    top: 24px;
}

.scroll-indicator-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Subtle bounce animation for bottom indicator */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
        opacity: 0.4;
    }
    40% {
        transform: translateX(-50%) translateY(-3px);
        opacity: 0.7;
    }
    60% {
        transform: translateX(-50%) translateY(-1px);
        opacity: 0.6;
    }
}

/* Subtle pulse animation for attention */
@keyframes subtle-pulse {
    0%, 100% {
        opacity: 0.4;
        height: 20px;
    }
    50% {
        opacity: 0.7;
        height: 24px;
    }
}

.scroll-indicator.attention {
    animation: bounce 2s infinite, subtle-pulse 3s infinite;
}

/* ===================================
   SCROLL CONTAINER SETUP
   =================================== */

/* Base class for any scrollable container */
.scroll-container {
    position: relative;
    overflow-y: auto;
    overflow-x: hidden;
}

/* Dashboard scroll setup */
.dashboard-content {
    position: relative;
}

/* Sidebar scroll setup */
.sidebar-nav {
    position: relative;
}

/* Main content scroll setup */
.main-content {
    position: relative;
}


/* ===================================
   SMOOTH SCROLLING BEHAVIOR
   =================================== */

/* Smooth scroll for all containers */
.scroll-container,
.dashboard-content,
.sidebar-nav,
.main-content {
    scroll-behavior: smooth;
}

/* Scroll padding for better UX */
.scroll-container {
    scroll-padding-top: var(--space-lg);
    scroll-padding-bottom: var(--space-lg);
}

/* ===================================
   RESPONSIVE SCROLL INDICATORS
   =================================== */

@media (max-width: 768px) {
    .scroll-indicator {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .scroll-indicator:hover {
        transform: translateX(-50%) scale(1.05);
    }
    
    .scroll-indicator-bottom {
        bottom: 16px;
    }
    
    .scroll-indicator-top {
        top: 16px;
    }
}

/* ===================================
   ACCESSIBILITY
   =================================== */

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .scroll-indicator {
        animation: none !important;
    }
    
    @keyframes bounce {
        0%, 100% {
            transform: translateX(-50%) translateY(0);
        }
    }
}

/* Focus styles for keyboard navigation */
.scroll-indicator:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}
