/**
 * Mobile-First Responsive CSS for client.expert
 *
 * This stylesheet implements a mobile-first responsive design approach
 * with breakpoints at: 576px (sm), 768px (md), 992px (lg), 1200px (xl)
 *
 * Minimum supported viewport: 375px
 */

/* ==========================================================================
   CSS Custom Properties (Mobile-First Base Values)
   ========================================================================== */
:root {
    /* Touch target sizes - iOS/Android guidelines recommend 44px minimum */
    --touch-target-min: 44px;
    --touch-target-comfortable: 48px;

    /* Spacing scale (mobile-first) */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;

    /* Typography scale (mobile-first) */
    --font-size-xs: 0.75rem;    /* 12px */
    --font-size-sm: 0.875rem;   /* 14px */
    --font-size-base: 1rem;     /* 16px - prevents iOS zoom on focus */
    --font-size-lg: 1.125rem;   /* 18px */
    --font-size-xl: 1.25rem;    /* 20px */
    --font-size-2xl: 1.5rem;    /* 24px */
    --font-size-3xl: 1.875rem;  /* 30px */

    /* Border radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-full: 50%;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 350ms ease;

    /* Z-index scale - Modals must be above all navigation */
    --z-dropdown: 1000;
    --z-sticky: 1020;
    --z-fixed: 1030;
    --z-sidebar: 1035;
    --z-bottom-nav: 1040;
    --z-modal-backdrop: 1050;
    --z-modal: 1055;
    --z-popover: 1060;
    --z-tooltip: 1070;

    /* Bottom navigation height */
    --bottom-nav-height: 64px;
    --bottom-nav-height-with-safe: calc(64px + env(safe-area-inset-bottom, 0px));

    /* Sidebar width */
    --sidebar-width: 280px;
    --sidebar-collapsed-width: 0px;
}

/* ==========================================================================
   Base Mobile Styles (No Media Query - Default)
   ========================================================================== */

/* Prevent horizontal scroll */
html, body {
    overflow-x: hidden;
    max-width: 100vw;
}

/* Improve text rendering on mobile */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Ensure inputs don't zoom on iOS (16px minimum) */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="url"],
input[type="search"],
input[type="date"],
input[type="time"],
input[type="datetime-local"],
select,
textarea {
    font-size: var(--font-size-base) !important;
}

/* ==========================================================================
   Touch-Friendly Elements
   ========================================================================== */

/* Buttons - ensure minimum touch target */
.btn {
    min-height: var(--touch-target-min);
    min-width: var(--touch-target-min);
    padding: var(--spacing-sm) var(--spacing-md);
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

/* Small buttons on mobile should still be tappable */
.btn-sm {
    min-height: 38px;
    padding: var(--spacing-xs) var(--spacing-sm);
}

/* Form controls - touch-friendly */
.form-control,
.form-select {
    min-height: var(--touch-target-min);
    padding: var(--spacing-sm) var(--spacing-md);
    touch-action: manipulation;
}

/* Checkboxes and radio buttons */
.form-check-input {
    width: 22px;
    height: 22px;
    margin-top: 0;
}

.form-check-label {
    padding-left: var(--spacing-xs);
    min-height: var(--touch-target-min);
    display: flex;
    align-items: center;
}

/* Links in lists/tables should have adequate touch targets */
.list-group-item,
.nav-link,
.dropdown-item {
    min-height: var(--touch-target-min);
    padding: var(--spacing-sm) var(--spacing-md);
}

/* Table rows - ensure tappable area */
.table td,
.table th {
    padding: var(--spacing-sm);
    vertical-align: middle;
}

/* ==========================================================================
   Sidebar Mobile Styles
   ========================================================================== */

/* Mobile sidebar - off-canvas by default */
.sidebar-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    height: 100dvh;
    z-index: var(--z-sidebar);
    transform: translateX(-100%);
    transition: transform var(--transition-base);
    background: var(--pastel-sidebar-bg, #e8f4f8);
    box-shadow: none;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    /* Ensure visibility - sidebar is positioned off-screen, not display:none */
    visibility: visible;
}

.sidebar-wrapper.show {
    transform: translateX(0);
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
}

/* Sidebar backdrop for mobile */
.sidebar-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    z-index: calc(var(--z-sidebar) - 1);
    transition: opacity var(--transition-base), visibility var(--transition-base);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.sidebar-backdrop.show {
    opacity: 1;
    visibility: visible;
}

/* Sidebar toggle button (FAB style) */
.sidebar-toggle {
    position: fixed;
    bottom: calc(var(--bottom-nav-height-with-safe) + var(--spacing-md));
    right: var(--spacing-md);
    width: 56px;
    height: 56px;
    border-radius: var(--radius-full);
    z-index: var(--z-fixed);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(125, 169, 233, 0.4);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.sidebar-toggle:active {
    transform: scale(0.95);
}

/* Sidebar navigation items */
.sidebar .nav-link {
    padding: var(--spacing-md);
    border-radius: var(--radius-sm);
    margin-bottom: var(--spacing-xs);
    min-height: var(--touch-target-comfortable);
    display: flex;
    align-items: center;
}

/* ==========================================================================
   Bottom Navigation Bar
   ========================================================================== */

.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--bottom-nav-height-with-safe);
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-top: 1px solid rgba(125, 169, 233, 0.2);
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    padding-top: var(--spacing-sm);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    z-index: var(--z-bottom-nav);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: var(--touch-target-comfortable);
    min-height: var(--touch-target-comfortable);
    padding: var(--spacing-xs);
    text-decoration: none;
    color: var(--pastel-dark, #495057);
    transition: color var(--transition-fast), transform var(--transition-fast);
    -webkit-tap-highlight-color: transparent;
    position: relative;
}

.bottom-nav-item i {
    font-size: 1.25rem;
    margin-bottom: 2px;
    transition: transform var(--transition-fast);
}

.bottom-nav-item span {
    font-size: var(--font-size-xs);
    font-weight: 500;
    white-space: nowrap;
}

.bottom-nav-item.active {
    color: var(--pastel-primary-dark, #7da9e9);
}

.bottom-nav-item.active i {
    transform: scale(1.1);
}

.bottom-nav-item.active::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 32px;
    height: 3px;
    background: linear-gradient(90deg, var(--pastel-primary, #a5d8ff), var(--pastel-info, #b8c0ff));
    border-radius: 0 0 3px 3px;
}

.bottom-nav-item:active {
    transform: scale(0.95);
}

/* Badge on bottom nav items */
.bottom-nav-item .badge {
    position: absolute;
    top: 0;
    right: 50%;
    transform: translateX(50%);
    font-size: 10px;
    min-width: 18px;
    height: 18px;
    padding: 2px 5px;
    border-radius: 9px;
}

/* ==========================================================================
   Page Header Mobile Styles
   ========================================================================== */

.page-header {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    padding: var(--spacing-md) 0;
    margin-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.page-header h1,
.page-header .h2 {
    font-size: var(--font-size-xl);
    margin-bottom: 0;
}

.page-header .btn-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    width: 100%;
}

.page-header .btn-group {
    flex: 1;
    min-width: fit-content;
}

/* ==========================================================================
   Stat Cards - Mobile-First Compact Design
   ========================================================================== */

.stat-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
    margin-bottom: var(--spacing-sm);
}

/* Compact stat card for mobile */
.stat-card {
    padding: 8px 6px;
    border-radius: var(--radius-sm);
    text-align: center;
}

.stat-card .card-body {
    padding: 8px 6px !important;
}

.stat-card .stat-value,
.stat-card .card-title,
.stat-card h3,
.stat-card h4,
.stat-card .h3,
.stat-card .h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 2px;
    line-height: 1.2;
}

.stat-card .stat-label,
.stat-card .card-text,
.stat-card p {
    font-size: 0.7rem;
    opacity: 0.9;
    margin-bottom: 0;
    line-height: 1.2;
}

.stat-card .stat-icon {
    font-size: 1rem;
    margin-bottom: 4px;
    opacity: 0.8;
}

.stat-card .stat-icon i,
.stat-card i.fa-2x {
    font-size: 1rem !important;
}

/* Task stats specific - 6 cards in 3x2 grid on mobile */
.task-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

/* Invoice/Payment stat cards - compact horizontal layout */
.stat-card-horizontal {
    padding: 10px 12px;
}

.stat-card-horizontal .card-body {
    padding: 10px 12px !important;
}

.stat-card-horizontal h3,
.stat-card-horizontal .h3 {
    font-size: 1rem;
    margin-bottom: 0;
}

.stat-card-horizontal h6 {
    font-size: 0.7rem;
    margin-bottom: 2px;
}

.stat-card-horizontal i.fa-2x {
    font-size: 1.25rem !important;
}

/* ==========================================================================
   Filter Bar - Mobile (Modal-based)
   ========================================================================== */

/* Mobile filter trigger button */
.filter-trigger {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    width: 100%;
    padding: var(--spacing-md);
    background: #fff;
    border: 1px solid rgba(125, 169, 233, 0.3);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    min-height: var(--touch-target-comfortable);
}

.filter-trigger i {
    color: var(--pastel-primary-dark, #7da9e9);
}

.filter-trigger .filter-count {
    margin-left: auto;
    background: var(--pastel-primary, #a5d8ff);
    color: var(--pastel-primary-dark, #7da9e9);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: var(--font-size-sm);
    font-weight: 600;
}

/* Active filter chips */
.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-md);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: var(--spacing-xs);
    scrollbar-width: none;
}

.filter-chips::-webkit-scrollbar {
    display: none;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-xs) var(--spacing-sm);
    background: var(--pastel-primary, #a5d8ff);
    color: var(--pastel-primary-dark, #7da9e9);
    border-radius: 16px;
    font-size: var(--font-size-sm);
    white-space: nowrap;
    min-height: 32px;
}

.filter-chip .chip-remove {
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-full);
    cursor: pointer;
    margin-left: var(--spacing-xs);
}

/* Filter modal on mobile */
.filter-modal .modal-dialog {
    margin: 0;
    max-width: 100%;
    height: 100%;
}

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

.filter-modal .modal-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: var(--spacing-md);
}

.filter-modal .modal-body {
    padding: var(--spacing-md);
    overflow-y: auto;
}

.filter-modal .modal-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding: var(--spacing-md);
    gap: var(--spacing-sm);
}

.filter-modal .filter-group {
    margin-bottom: var(--spacing-lg);
}

.filter-modal .filter-group-label {
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--pastel-dark, #495057);
}

/* ==========================================================================
   Kanban Board - Mobile (Vertical Stack)
   ========================================================================== */

.kanban-board {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    padding-bottom: calc(var(--bottom-nav-height-with-safe) + var(--spacing-xl));
}

.kanban-column {
    flex: none;
    width: 100%;
    min-height: auto;
    background: #f8f9fa;
    border-radius: var(--radius-md);
    overflow: hidden;
}

.kanban-column-header {
    padding: var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10;
}

.kanban-column-title {
    font-weight: 600;
    margin: 0;
}

.kanban-column-count {
    background: rgba(0, 0, 0, 0.1);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: var(--font-size-sm);
}

.kanban-tasks {
    padding: var(--spacing-sm);
    max-height: 300px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.kanban-task {
    background: #fff;
    border-radius: var(--radius-sm);
    padding: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
    border-left: 4px solid #ced4da;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    touch-action: pan-y;
    min-height: var(--touch-target-comfortable);
}

.kanban-task-title {
    font-weight: 600;
    margin-bottom: var(--spacing-xs);
    font-size: var(--font-size-sm);
}

.kanban-task-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: var(--font-size-xs);
    color: #6c757d;
}

/* ==========================================================================
   Data Tables - Mobile Responsive
   ========================================================================== */

/* Hide low-priority columns on mobile */
.table-responsive {
    margin: 0 calc(-1 * var(--spacing-md));
    padding: 0 var(--spacing-md);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* DataTables responsive child rows */
table.dataTable.dtr-inline.collapsed > tbody > tr > td.dtr-control::before,
table.dataTable.dtr-inline.collapsed > tbody > tr > th.dtr-control::before {
    top: 50%;
    transform: translateY(-50%);
    margin-right: var(--spacing-sm);
}

/* Card-style rows for mobile tables */
.table-mobile-cards tbody tr {
    display: block;
    margin-bottom: var(--spacing-md);
    background: #fff;
    border-radius: var(--radius-md);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: var(--spacing-md);
}

.table-mobile-cards tbody td {
    display: flex;
    justify-content: space-between;
    padding: var(--spacing-xs) 0;
    border: none;
}

.table-mobile-cards tbody td::before {
    content: attr(data-label);
    font-weight: 600;
    color: #6c757d;
}

.table-mobile-cards thead {
    display: none;
}

/* ==========================================================================
   Modal - Z-Index Override (Ensure modals appear above all navigation)
   ========================================================================== */

.modal {
    z-index: var(--z-modal) !important;
}

.modal-backdrop {
    z-index: var(--z-modal-backdrop) !important;
}

/* ==========================================================================
   Modal - Mobile Fullscreen
   ========================================================================== */

.modal-mobile-fullscreen .modal-dialog {
    margin: 0;
    max-width: 100%;
    min-height: 100%;
}

.modal-mobile-fullscreen .modal-content {
    min-height: 100vh;
    min-height: 100dvh;
    border-radius: 0;
    border: none;
}

.modal-mobile-fullscreen .modal-header {
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
    padding: var(--spacing-md);
}

.modal-mobile-fullscreen .modal-body {
    padding: var(--spacing-md);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.modal-mobile-fullscreen .modal-footer {
    position: sticky;
    bottom: 0;
    background: #fff;
    padding: var(--spacing-md);
    padding-bottom: calc(var(--spacing-md) + env(safe-area-inset-bottom, 0px));
}

/* ==========================================================================
   Cards - Mobile Responsive
   ========================================================================== */

.card {
    margin-bottom: var(--spacing-md);
}

.card-header {
    padding: var(--spacing-md);
}

.card-body {
    padding: var(--spacing-md);
}

/* Dashboard stat cards */
.dashboard-stats .col-md-3 {
    margin-bottom: var(--spacing-sm);
}

/* ==========================================================================
   Login Page - Mobile Optimized
   ========================================================================== */

.login-container {
    padding: var(--spacing-md);
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-card {
    margin: 0 auto;
    max-width: 100%;
}

/* Reduce/optimize floating shapes on mobile */
.floating-shapes .shape {
    width: 200px;
    height: 200px;
    filter: blur(60px);
    animation-duration: 6s;
}

.floating-shapes .shape-1,
.floating-shapes .shape-3 {
    display: none;
}

/* ==========================================================================
   Content Area - Account for Bottom Nav
   ========================================================================== */

.content-with-bottom-nav {
    padding-bottom: calc(var(--bottom-nav-height-with-safe) + var(--spacing-xl));
}

/* Main content wrapper adjustments */
.col-md-9.col-xl-10 {
    padding: var(--spacing-md);
    padding-bottom: calc(var(--bottom-nav-height-with-safe) + var(--spacing-xl));
}

/* ==========================================================================
   Utility Classes - Mobile
   ========================================================================== */

/* Hide on mobile, show on larger screens */
.hide-mobile {
    display: none !important;
}

/* Show only on mobile */
.show-mobile {
    display: block !important;
}

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

.show-mobile-inline {
    display: inline !important;
}

/* Touch-friendly spacing */
.touch-spacing {
    padding: var(--spacing-md);
}

/* Prevent text selection during touch interactions */
.no-select {
    -webkit-user-select: none;
    user-select: none;
}

/* ==========================================================================
   Small Devices (sm) - 576px and up
   ========================================================================== */
@media (min-width: 576px) {
    :root {
        --spacing-md: 20px;
        --spacing-lg: 28px;
    }

    .page-header h1,
    .page-header .h2 {
        font-size: var(--font-size-2xl);
    }

    /* Stat cards - slightly larger on small tablets */
    .stat-cards-grid {
        gap: 8px;
    }

    .stat-card {
        padding: 10px 8px;
    }

    .stat-card .card-body {
        padding: 10px 8px !important;
    }

    .stat-card .stat-value,
    .stat-card .card-title,
    .stat-card h3,
    .stat-card h4,
    .stat-card .h3,
    .stat-card .h4 {
        font-size: 1.25rem;
    }

    .stat-card .stat-label,
    .stat-card .card-text,
    .stat-card p {
        font-size: 0.75rem;
    }

    .stat-card .stat-icon i,
    .stat-card i.fa-2x {
        font-size: 1.25rem !important;
    }

    .task-stats-grid {
        gap: 8px;
    }

    /* Login card max-width */
    .login-card {
        max-width: 400px;
    }
}

/* ==========================================================================
   Medium Devices (md) - 768px and up (Tablets)
   ========================================================================== */
@media (min-width: 768px) {
    :root {
        --spacing-md: 24px;
        --spacing-lg: 32px;
    }

    /* Hide bottom nav on tablets and up */
    .bottom-nav {
        display: none;
    }

    /* Hide mobile-only elements */
    .show-mobile,
    .show-mobile-flex,
    .show-mobile-inline {
        display: none !important;
    }

    /* Show desktop-only elements */
    .hide-mobile {
        display: block !important;
    }

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

    /* Sidebar - visible by default on desktop */
    .sidebar-wrapper {
        position: relative;
        left: 0;
        width: auto;
        height: auto;
        z-index: auto;
        box-shadow: none;
        transform: none;
        transition: none;
    }

    .sidebar-toggle {
        display: none;
    }

    .sidebar-backdrop {
        display: none;
    }

    /* Content area - no bottom nav padding needed */
    .content-with-bottom-nav,
    .col-md-9.col-xl-10 {
        padding-bottom: var(--spacing-xl);
    }

    /* Page header - horizontal layout */
    .page-header {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .page-header .btn-toolbar {
        width: auto;
    }

    /* Stat cards - 3 columns on tablets with larger padding */
    .stat-cards-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    .stat-card {
        padding: 12px;
    }

    .stat-card .card-body {
        padding: 12px !important;
    }

    .stat-card .stat-value,
    .stat-card .card-title,
    .stat-card h3,
    .stat-card h4,
    .stat-card .h3,
    .stat-card .h4 {
        font-size: 1.5rem;
    }

    .stat-card .stat-label,
    .stat-card .card-text,
    .stat-card p {
        font-size: 0.8rem;
    }

    .stat-card .stat-icon i,
    .stat-card i.fa-2x {
        font-size: 1.5rem !important;
    }

    .task-stats-grid {
        grid-template-columns: repeat(6, 1fr);
        gap: 12px;
    }

    /* Horizontal stat cards for invoices - full width on tablet */
    .stat-card-horizontal .card-body {
        padding: 16px !important;
    }

    .stat-card-horizontal h3,
    .stat-card-horizontal .h3 {
        font-size: 1.5rem;
    }

    .stat-card-horizontal h6 {
        font-size: 0.85rem;
    }

    .stat-card-horizontal i.fa-2x {
        font-size: 2rem !important;
    }

    /* Filter bar - inline on tablets */
    .filter-trigger {
        display: none;
    }

    .filter-bar-desktop {
        display: block;
    }

    /* Kanban - horizontal scroll */
    .kanban-board {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: var(--spacing-md);
    }

    .kanban-column {
        flex: 0 0 280px;
        min-height: 400px;
    }

    .kanban-tasks {
        max-height: none;
    }

    /* Modal - centered, not fullscreen */
    .modal-mobile-fullscreen .modal-dialog {
        margin: 1.75rem auto;
        max-width: 500px;
        min-height: auto;
    }

    .modal-mobile-fullscreen .modal-content {
        min-height: auto;
        border-radius: var(--radius-lg);
    }

    /* Table responsive - normal on tablets */
    .table-mobile-cards tbody tr {
        display: table-row;
        margin-bottom: 0;
        background: transparent;
        border-radius: 0;
        box-shadow: none;
        padding: 0;
    }

    .table-mobile-cards tbody td {
        display: table-cell;
        padding: var(--spacing-sm);
        border: inherit;
    }

    .table-mobile-cards tbody td::before {
        content: none;
    }

    .table-mobile-cards thead {
        display: table-header-group;
    }

    /* Login floating shapes */
    .floating-shapes .shape {
        width: 300px;
        height: 300px;
        filter: blur(40px);
    }

    .floating-shapes .shape-1,
    .floating-shapes .shape-3 {
        display: block;
    }
}

/* ==========================================================================
   Large Devices (lg) - 992px and up (Desktops)
   ========================================================================== */
@media (min-width: 992px) {
    :root {
        --font-size-xl: 1.5rem;
        --font-size-2xl: 1.75rem;
        --font-size-3xl: 2.25rem;
    }

    /* Stat cards - 4 columns on desktop */
    .stat-cards-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--spacing-md);
    }

    /* Task stats - 6 columns on desktop */
    .task-stats-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    /* Kanban columns slightly wider */
    .kanban-column {
        flex: 0 0 300px;
    }

    /* Login floating shapes full size */
    .floating-shapes .shape {
        filter: blur(40px);
        animation-duration: 3s;
    }

    .floating-shapes .shape-1 { width: 400px; height: 400px; }
    .floating-shapes .shape-2 { width: 350px; height: 350px; }
    .floating-shapes .shape-3 { width: 450px; height: 450px; }
    .floating-shapes .shape-4 { width: 300px; height: 300px; }
}

/* ==========================================================================
   Extra Large Devices (xl) - 1200px and up
   ========================================================================== */
@media (min-width: 1200px) {
    /* Kanban columns wider for more content */
    .kanban-column {
        flex: 0 0 320px;
    }

    /* More generous spacing */
    .card-body {
        padding: var(--spacing-lg);
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */
@media print {
    .bottom-nav,
    .sidebar-wrapper,
    .sidebar-toggle,
    .sidebar-backdrop,
    .filter-trigger,
    .btn-toolbar {
        display: none !important;
    }

    .col-md-9.col-xl-10 {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
    }
}

/* ==========================================================================
   Accessibility - Reduced Motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .floating-shapes .shape {
        animation: none;
    }
}

/* ==========================================================================
   Dark Mode Support (if system prefers)
   ========================================================================== */
@media (prefers-color-scheme: dark) {
    /* Reserve for future dark mode implementation */
}
