/*
!**
 * Mobile-Friendly CSS Enhancements for Cockatoo Cocktails System
 *
 * Add these styles to webroot/css/dashboard.css or create a new mobile.css file
 * Ensures consistent mobile UX across all pages for casual uni staff usage
 *!

!* ==========================================
   MOBILE TOUCH TARGETS & ACCESSIBILITY
   ========================================== *!

!* Minimum 44px touch targets for mobile accessibility *!
@media (max-width: 768px) {
    .btn {
        min-height: 44px;
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }

    .btn-sm {
        min-height: 40px;
        padding: 0.5rem 1rem;
    }

    .btn-lg {
        min-height: 48px;
        padding: 1rem 2rem;
        font-size: 1.1rem;
    }

    !* Form controls sized for mobile interaction *!
    .form-control,
    .form-select {
        min-height: 44px;
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }

    .form-control-lg,
    .form-select-lg {
        min-height: 48px;
        padding: 1rem 1.25rem;
        font-size: 1.1rem;
    }

    !* Better checkbox and radio button targets *!
    .form-check-input {
        width: 1.5rem;
        height: 1.5rem;
        margin-top: 0.125rem;
    }

    .form-check-label {
        padding-left: 0.5rem;
        min-height: 44px;
        display: flex;
        align-items: center;
    }
}

!* ==========================================
   MOBILE NAVIGATION & LAYOUT
   ========================================== *!

@media (max-width: 992px) {
    !* Collapsible sidebar behavior *!
    .layout-menu {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .layout-menu.show {
        transform: translateX(0);
    }

    !* Better mobile navbar *!
    .layout-navbar {
        padding: 0.5rem 1rem;
    }

    .navbar-nav .nav-link {
        padding: 0.75rem 1rem;
        min-height: 44px;
        display: flex;
        align-items: center;
    }
}

@media (max-width: 768px) {
    !* Mobile-first content spacing *!
    .container-xxl {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .content-wrapper {
        padding-top: 1rem;
    }

    !* Mobile card adjustments *!
    .card {
        margin-bottom: 1rem;
        border-radius: 0.5rem;
    }

    .card-body {
        padding: 1.25rem 1rem;
    }

    .card-header {
        padding: 1rem;
    }

    !* Better mobile breadcrumbs *!
    .breadcrumb {
        padding: 0.5rem 0;
        margin-bottom: 1rem;
        font-size: 0.875rem;
        background: none;
    }

    .breadcrumb-item + .breadcrumb-item::before {
        padding: 0 0.25rem;
        font-size: 0.75rem;
    }
}

!* ==========================================
   MOBILE TABLES & DATA DISPLAY
   ========================================== *!

@media (max-width: 768px) {
    !* Responsive table behavior *!
    .table-responsive {
        border: none;
    }

    .table-responsive .table {
        margin-bottom: 0;
    }

    !* Mobile-friendly table styling *!
    .table th,
    .table td {
        padding: 0.75rem 0.5rem;
        vertical-align: middle;
    }

    .table th {
        border-top: none;
        font-weight: 600;
        font-size: 0.875rem;
    }

    !* Stack table cells on very small screens *!
    .table-stack-mobile {
        display: block;
    }

    .table-stack-mobile thead,
    .table-stack-mobile tbody,
    .table-stack-mobile th,
    .table-stack-mobile td,
    .table-stack-mobile tr {
        display: block;
    }

    .table-stack-mobile thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }

    .table-stack-mobile tr {
        border: 1px solid #ddd;
        border-radius: 0.5rem;
        margin-bottom: 1rem;
        padding: 1rem;
        background: white;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    .table-stack-mobile td {
        border: none;
        padding: 0.5rem 0;
        text-align: right;
        padding-left: 50%;
        position: relative;
    }

    .table-stack-mobile td:before {
        content: attr(data-label) ": ";
        position: absolute;
        left: 0;
        width: 45%;
        padding-right: 10px;
        white-space: nowrap;
        text-align: left;
        font-weight: 600;
        color: #666;
    }
}

!* ==========================================
   MOBILE FORMS & INPUT ENHANCEMENTS
   ========================================== *!

@media (max-width: 768px) {
    !* Better form spacing *!
    .mb-3 {
        margin-bottom: 1.5rem !important;
    }

    !* Improved form labels *!
    .form-label {
        font-weight: 500;
        margin-bottom: 0.75rem;
        color: #333;
        font-size: 1rem;
    }

    !* Better select multiple on mobile *!
    select[multiple] {
        min-height: 120px;
        background-color: #fff;
    }

    !* Textarea improvements *!
    textarea.form-control {
        min-height: 100px;
        resize: vertical;
    }

    !* Date/time inputs *!
    input[type="datetime-local"],
    input[type="date"],
    input[type="time"] {
        min-height: 44px;
    }

    !* Form validation visual improvements *!
    .invalid-feedback {
        font-size: 0.9rem;
        margin-top: 0.5rem;
    }

    .valid-feedback {
        font-size: 0.9rem;
        margin-top: 0.5rem;
    }
}

!* ==========================================
   MOBILE MODAL & DROPDOWN ENHANCEMENTS
   ========================================== *!

@media (max-width: 768px) {
    !* Full-screen modals on mobile *!
    .modal-dialog {
        margin: 0;
        width: 100%;
        height: 100%;
        max-width: none;
    }

    .modal-content {
        height: 100%;
        border-radius: 0;
        border: none;
    }

    .modal-header {
        padding: 1rem;
        border-bottom: 1px solid #dee2e6;
    }

    .modal-body {
        padding: 1rem;
        flex: 1;
        overflow-y: auto;
    }

    .modal-footer {
        padding: 1rem;
        border-top: 1px solid #dee2e6;
    }

    !* Better dropdown positioning *!
    .dropdown-menu {
        border-radius: 0.5rem;
        box-shadow: 0 4px 16px rgba(0,0,0,0.15);
        border: none;
        min-width: 200px;
    }

    .dropdown-item {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }

    .dropdown-item:hover,
    .dropdown-item:focus {
        background-color: #f8f9fa;
    }
}

!* ==========================================
   MOBILE BADGES & STATUS INDICATORS
   ========================================== *!

@media (max-width: 768px) {
    .badge {
        font-size: 0.75rem;
        padding: 0.375rem 0.75rem;
        border-radius: 0.375rem;
    }

    .badge-lg {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }

    !* Avatar improvements for mobile *!
    .avatar {
        border-radius: 50%;
    }

    .avatar-sm {
        width: 2rem;
        height: 2rem;
    }

    .avatar,
    .avatar-md {
        width: 2.5rem;
        height: 2.5rem;
    }

    .avatar-lg {
        width: 3rem;
        height: 3rem;
    }

    .avatar-xl {
        width: 4rem;
        height: 4rem;
    }
}

!* ==========================================
   MOBILE ALERT & FEEDBACK IMPROVEMENTS
   ========================================== *!

@media (max-width: 768px) {
    .alert {
        border-radius: 0.5rem;
        padding: 1rem;
        margin-bottom: 1rem;
        border: none;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    .alert-dismissible .btn-close {
        padding: 1rem;
        margin: -1rem -1rem -1rem auto;
    }

    !* Flash message improvements *!
    .flash-message {
        position: fixed;
        top: 1rem;
        left: 1rem;
        right: 1rem;
        z-index: 1050;
        animation: slideDown 0.3s ease;
    }

    @keyframes slideDown {
        from {
            transform: translateY(-100%);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }
}

!* ==========================================
   MOBILE UTILITY CLASSES
   ========================================== *!

!* Hide on mobile *!
@media (max-width: 768px) {
    .d-mobile-none {
        display: none !important;
    }

    .d-mobile-block {
        display: block !important;
    }

    .d-mobile-flex {
        display: flex !important;
    }

    !* Mobile-specific spacing *!
    .p-mobile-1 {
        padding: 0.5rem !important;
    }

    .p-mobile-2 {
        padding: 1rem !important;
    }

    .m-mobile-1 {
        margin: 0.5rem !important;
    }

    .m-mobile-2 {
        margin: 1rem !important;
    }

    !* Mobile text sizing *!
    .text-mobile-sm {
        font-size: 0.875rem !important;
    }

    .text-mobile-lg {
        font-size: 1.125rem !important;
    }
}

!* ==========================================
   MOBILE PERFORMANCE & ANIMATIONS
   ========================================== *!

!* Reduce animations on mobile for better performance *!
@media (max-width: 768px) {
    * {
        animation-duration: 0.2s !important;
        transition-duration: 0.2s !important;
    }

    !* Disable hover effects on touch devices *!
    .no-touch-hover:hover {
        transform: none !important;
        box-shadow: inherit !important;
    }
}

!* Touch device optimizations *!
@media (hover: none) and (pointer: coarse) {
    .btn:hover {
        transform: none;
        box-shadow: inherit;
    }

    .card:hover {
        transform: none;
        box-shadow: inherit;
    }
}

!* ==========================================
   MOBILE DARK MODE SUPPORT (if needed)
   ========================================== *!

!*@media (max-width: 768px) and (prefers-color-scheme: dark) {
    .card {
        background-color: #2c2c54;
        color: #fff;
    }

    .form-control,
    .form-select {
        background-color: #40407a;
        border-color: #706fd3;
        color: #fff;
    }

    .form-control:focus,
    .form-select:focus {
        background-color: #40407a;
        border-color: #696cff;
        color: #fff;
    }
}*!
*/
