feat: Comprehensive mobile UI improvements

Dashboard mobile changes:
- Sidebar becomes slide-out drawer with overlay
- Added mobile filter toggle button
- Table wrapped for horizontal scroll
- Stats grid: 2 columns on tablet, 1 on phone
- Larger touch targets (44px minimum)
- Full-width modals with better spacing
- Admin dropdown slides up from bottom
- Fixed bulk action bar at bottom

Ticket page mobile changes:
- Stack metadata vertically
- Full-width buttons and inputs
- Scrollable tabs
- Better comment form layout
- Improved timeline readability

General:
- Prevent iOS zoom with 16px input font
- Touch-friendly spacing throughout

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-23 22:10:29 -05:00
parent ee317d6662
commit 7465fb6fc4
4 changed files with 619 additions and 0 deletions

View File

@@ -3849,3 +3849,347 @@ table td:nth-child(4) {
min-height: 200px;
}
}
/* ===== COMPREHENSIVE MOBILE IMPROVEMENTS ===== */
@media (max-width: 768px) {
/* Prevent iOS zoom on input focus */
input, select, textarea {
font-size: 16px !important;
}
/* Make sidebar a slide-out drawer */
.dashboard-sidebar {
position: fixed;
top: 0;
left: -100%;
width: 85%;
max-width: 320px;
height: 100vh;
max-height: 100vh;
z-index: 1000;
background: var(--bg-primary);
transition: left 0.3s ease;
padding: 1rem;
overflow-y: auto;
box-shadow: 4px 0 20px rgba(0, 0, 0, 0.5);
}
.dashboard-sidebar.mobile-open {
left: 0;
}
/* Mobile sidebar overlay */
.mobile-sidebar-overlay {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.7);
z-index: 999;
}
.mobile-sidebar-overlay.active {
display: block;
}
/* Mobile filter toggle button */
.mobile-filter-toggle {
display: flex !important;
align-items: center;
gap: 0.5rem;
padding: 0.75rem 1rem;
background: var(--bg-secondary);
border: 2px solid var(--terminal-green);
color: var(--terminal-green);
font-family: var(--font-mono);
font-size: 0.9rem;
cursor: pointer;
margin-bottom: 1rem;
width: 100%;
}
.mobile-filter-toggle:active {
background: var(--terminal-green);
color: var(--bg-primary);
}
/* Close button in mobile sidebar */
.mobile-sidebar-close {
display: block !important;
position: absolute;
top: 0.5rem;
right: 0.5rem;
width: 44px;
height: 44px;
background: transparent;
border: 2px solid var(--terminal-green);
color: var(--terminal-green);
font-size: 1.5rem;
cursor: pointer;
z-index: 10;
}
/* Better header on mobile */
.user-header {
flex-wrap: wrap;
padding: 0.5rem;
gap: 0.5rem;
}
.header-left {
flex: 1;
min-width: 0;
}
.header-right {
width: 100%;
justify-content: space-between;
flex-wrap: wrap;
gap: 0.5rem;
}
.app-title {
font-size: 1rem;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
/* Compact header buttons */
.header-btn, .settings-btn, .new-ticket-btn {
padding: 0.5rem 0.75rem;
font-size: 0.85rem;
min-height: 44px;
}
/* Table wrapper for horizontal scroll */
.table-wrapper {
width: 100%;
overflow-x: auto;
-webkit-overflow-scrolling: touch;
margin-bottom: 1rem;
}
.table-wrapper table {
min-width: 600px;
}
/* Larger touch targets for table rows */
table td, table th {
padding: 12px 8px;
}
table td a {
display: inline-block;
padding: 4px 0;
}
/* Stats widgets - 2 per row */
.stats-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 0.5rem;
}
.stat-card {
padding: 0.75rem;
min-height: 70px;
}
.stat-value {
font-size: 1.5rem;
}
.stat-label {
font-size: 0.7rem;
}
/* Better toolbar on mobile */
.toolbar {
flex-direction: column;
gap: 0.75rem;
}
.toolbar-search {
width: 100%;
order: -1;
}
.toolbar-actions {
width: 100%;
flex-wrap: wrap;
gap: 0.5rem;
}
.toolbar-actions .btn {
flex: 1;
min-width: 100px;
text-align: center;
}
/* Full width modals on mobile */
.modal-overlay {
padding: 0.5rem;
align-items: flex-start;
padding-top: 2rem;
}
.modal-content {
width: 100% !important;
max-width: 100% !important;
max-height: calc(100vh - 4rem);
margin: 0;
}
.modal-body {
max-height: calc(100vh - 12rem);
overflow-y: auto;
}
/* Better form elements */
.modal-body input,
.modal-body select,
.modal-body textarea {
width: 100%;
min-height: 44px;
padding: 0.75rem;
margin-bottom: 0.75rem;
}
.modal-footer {
flex-direction: column;
gap: 0.5rem;
}
.modal-footer button {
width: 100%;
min-height: 48px;
}
/* Settings modal improvements */
.settings-content {
width: 100% !important;
max-width: 100% !important;
height: auto;
max-height: 90vh;
}
/* Better pagination */
.pagination {
flex-wrap: wrap;
justify-content: center;
gap: 0.25rem;
}
.pagination button,
.pagination a {
min-width: 44px;
min-height: 44px;
padding: 0.5rem;
}
/* Admin dropdown improvements */
.admin-dropdown {
position: static;
}
.admin-dropdown-content {
position: fixed;
left: 0;
right: 0;
top: auto;
bottom: 0;
width: 100%;
max-height: 50vh;
overflow-y: auto;
border-radius: 0;
}
.admin-dropdown-content a {
padding: 1rem;
min-height: 48px;
}
/* Bulk action bar on mobile */
.bulk-action-bar {
position: fixed;
bottom: 0;
left: 0;
right: 0;
z-index: 100;
flex-wrap: wrap;
padding: 0.75rem;
gap: 0.5rem;
max-height: 50vh;
overflow-y: auto;
}
.bulk-action-bar button {
flex: 1 1 calc(50% - 0.5rem);
min-height: 44px;
}
/* View toggle more accessible */
.view-toggle {
margin-bottom: 1rem;
}
.view-btn {
flex: 1;
min-height: 48px;
}
/* Better quick actions */
.quick-actions {
display: flex;
gap: 0.25rem;
}
.quick-action-btn {
min-width: 36px;
min-height: 36px;
padding: 0.25rem;
}
}
/* Extra small screens */
@media (max-width: 480px) {
.app-title {
font-size: 0.9rem;
}
.stats-row {
grid-template-columns: 1fr;
}
.stat-card {
padding: 1rem;
}
/* Hide certain table columns */
table th:nth-child(4),
table td:nth-child(4),
table th:nth-child(6),
table td:nth-child(6) {
display: none;
}
.toolbar-actions .btn span {
display: none;
}
.header-right {
justify-content: flex-end;
}
.new-ticket-btn span {
display: none;
}
.new-ticket-btn::before {
content: '+';
font-size: 1.2rem;
}
}