/**
 * @file app/shared/styles/mobile-navigation.css
 * @brief Stylesheet for mobile-navigation
 * 
 * @version 
 *  - Major: 1
 *  - Minor: 1
 *  - Subversion: 0
 * 
 * @date 
 *  - Created: 2025-08-07 11:33:53
 *  - Modified: 2025-08-07 11:33:53
 * 
 * @author [core] Informationstechnologie
 * 
 * @copyright [core] Informationstechnologie, 2025
 */


/* Mobile Navigation Styles */

/* Hamburger Menu Icon */
.mobile-menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    padding: 0;
    background: transparent;
    border: none;
    cursor: pointer;
    position: relative;
    z-index: 1051;
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

.hamburger-icon {
    width: 24px;
    height: 18px;
    position: relative;
    transform: rotate(0deg);
    transition: .3s ease-in-out;
    cursor: pointer;
}

.hamburger-icon span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: #333;
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: .25s ease-in-out;
}

.hamburger-icon span:nth-child(1) {
    top: 0px;
}

.hamburger-icon span:nth-child(2) {
    top: 7px;
}

.hamburger-icon span:nth-child(3) {
    top: 14px;
}

/* Animated X when active */
.hamburger-icon.active span:nth-child(1) {
    top: 7px;
    transform: rotate(135deg);
}

.hamburger-icon.active span:nth-child(2) {
    opacity: 0;
    left: -60px;
}

.hamburger-icon.active span:nth-child(3) {
    top: 7px;
    transform: rotate(-135deg);
}

/* Mobile Sidebar Styles */
@media (max-width: 768px) {
    .sidebar {
        position: fixed !important;
        top: 0;
        left: 0;
        width: 280px;
        height: 100vh;
        background: #fff;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        z-index: 1050;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        overflow-y: auto;
    }
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    /* Sidebar Header */
    .sidebar-header {
        padding: 1rem;
        border-bottom: 1px solid #e9ecef;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    
    .sidebar-close {
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        cursor: pointer;
        font-size: 1.5rem;
        color: #6c757d;
    }
    
    /* Sidebar Backdrop */
    .sidebar-backdrop {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1040;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
    }
    
    .sidebar-backdrop.show {
        opacity: 1;
        visibility: visible;
    }
    
    /* Prevent body scroll when sidebar open */
    body.sidebar-open {
        overflow: hidden;
    }
}

/* Mobile Bottom Navigation */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid #e9ecef;
    display: none;
    z-index: 1030;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: flex;
        justify-content: space-around;
        padding: 0.5rem 0;
    }
    
    .mobile-bottom-nav-item {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 0.5rem;
        color: #6c757d;
        text-decoration: none;
        transition: color 0.2s ease;
        cursor: pointer;
        background: transparent;
        border: none;
    }
    
    .mobile-bottom-nav-item:hover,
    .mobile-bottom-nav-item:focus {
        color: var(--primary-color, #0d6efd);
    }
    
    .mobile-bottom-nav-item.active {
        color: var(--primary-color, #0d6efd);
    }
    
    .mobile-bottom-nav-icon {
        font-size: 1.25rem;
        margin-bottom: 0.25rem;
    }
    
    .mobile-bottom-nav-label {
        font-size: 0.75rem;
        font-weight: 500;
    }
}

/* Mobile Header */
.mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 56px;
    background: #fff;
    border-bottom: 1px solid #e9ecef;
    display: none;
    align-items: center;
    padding: 0 1rem;
    z-index: 1030;
}

@media (max-width: 768px) {
    .mobile-header {
        display: flex;
    }
    
    /* Adjust main content for fixed header */
    .main-content {
        padding-top: 56px !important;
        padding-bottom: 60px; /* For bottom nav */
    }
}

.mobile-header-title {
    flex: 1;
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-header-actions {
    display: flex;
    gap: 0.5rem;
}

.mobile-header-action {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    cursor: pointer;
    color: #6c757d;
    font-size: 1.25rem;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.mobile-header-action:hover {
    background-color: #f8f9fa;
}

/* Swipe Indicators */
.swipe-indicator {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 60px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 0 10px 10px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1035;
}

.swipe-indicator.left {
    left: 0;
}

.swipe-indicator.right {
    right: 0;
    border-radius: 10px 0 0 10px;
}

@media (max-width: 768px) {
    .swipe-indicator {
        display: flex;
    }
    
    body:hover .swipe-indicator {
        opacity: 0.5;
    }
}

/* Mobile Floating Action Button */
.mobile-fab {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 56px;
    height: 56px;
    background: var(--primary-color, #0d6efd);
    color: white;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    border: none;
    font-size: 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    z-index: 1025;
}

@media (max-width: 768px) {
    .mobile-fab {
        display: flex;
    }
}

.mobile-fab:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.mobile-fab:active {
    transform: scale(0.95);
}

/* Mobile Search Bar */
.mobile-search {
    position: sticky;
    top: 56px;
    background: #fff;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e9ecef;
    z-index: 100;
    display: none;
}

@media (max-width: 768px) {
    .mobile-search {
        display: block;
    }
}

.mobile-search-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    background: #f8f9fa;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.mobile-search-input:focus {
    outline: none;
    border-color: var(--primary-color, #0d6efd);
    background: #fff;
}

/* Pull to Refresh */
.pull-to-refresh {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
    z-index: 1020;
}

.pull-to-refresh.show {
    transform: translateY(56px);
}

.pull-to-refresh-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e9ecef;
    border-top-color: var(--primary-color, #0d6efd);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Mobile Gesture Hints */
.gesture-hint {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    z-index: 1060;
}

.gesture-hint.show {
    opacity: 1;
    visibility: visible;
}

/* Responsive Utilities */
@media (max-width: 768px) {
    /* Hide desktop elements */
    .d-mobile-none {
        display: none !important;
    }
    
    /* Show mobile elements */
    .d-mobile-block {
        display: block !important;
    }
    
    .d-mobile-flex {
        display: flex !important;
    }
    
    .d-mobile-inline-flex {
        display: inline-flex !important;
    }
    
    /* Mobile padding adjustments */
    .p-mobile-0 { padding: 0 !important; }
    .p-mobile-1 { padding: 0.25rem !important; }
    .p-mobile-2 { padding: 0.5rem !important; }
    .p-mobile-3 { padding: 1rem !important; }
    .px-mobile-3 { padding-left: 1rem !important; padding-right: 1rem !important; }
    .py-mobile-3 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
    
    /* Mobile margin adjustments */
    .m-mobile-0 { margin: 0 !important; }
    .m-mobile-1 { margin: 0.25rem !important; }
    .m-mobile-2 { margin: 0.5rem !important; }
    .m-mobile-3 { margin: 1rem !important; }
}