/* ==========================================================================
   TICKET LIST VIEW // ENTERPRISE STYLING (ticket_list.css)
   ========================================================================== */

:root {
    --ticket-list-primary: #0d6efd;
    --ticket-list-surface: #ffffff;
    --ticket-list-text: #334155;
    --ticket-list-border: #e2e8f0;
    --ticket-list-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.04), 0 2px 4px -2px rgba(15, 23, 42, 0.04);
    --ticket-list-hover-shadow: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.08);
    --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Container & Overflow Protection */
body {
    overflow-x: hidden !important;
}

.ticket-list-container {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* Cards & Containers */
.card {
    border-radius: 0.85rem;
    border: 1px solid var(--ticket-list-border);
    box-shadow: var(--ticket-list-shadow);
    background-color: var(--ticket-list-surface);
    transition: var(--transition-smooth);
    overflow: hidden;
}

.card:hover {
    box-shadow: var(--ticket-list-hover-shadow);
}

/* Tables & Responsive Wrapper */
.table-responsive {
    width: 100%;
    margin-bottom: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table {
    color: var(--ticket-list-text);
    vertical-align: middle;
    margin-bottom: 0;
    width: 100%;
}

.table > :not(caption) > * > * {
    padding: 0.75rem 0.75rem;
}

.table thead th {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    background-color: #f8fafc;
    border-bottom: 2px solid var(--ticket-list-border);
    white-space: nowrap;
}

/* ==========================================================================
   MOBILE RESPONSIVE STYLING & ZOOM RESILIENCE (Viewports <= 767.98px)
   ========================================================================== */

@media (max-width: 767.98px) {
    body {
        overflow-x: hidden !important;
    }

    .container {
        padding-left: 12px !important;
        padding-right: 12px !important;
        max-width: 100% !important;
    }

    .ticket-list-container {
        padding: 0 !important;
    }

    /* Header & Button Stacking */
    .d-flex.justify-content-between.align-items-center.mb-3 {
        flex-direction: column;
        align-items: stretch !important;
        gap: 0.85rem;
    }

    .d-flex.justify-content-between.align-items-center.mb-3 h2 {
        font-size: 1.35rem;
    }

    .btn-group {
        display: flex;
        flex-wrap: wrap;
        width: 100%;
    }

    .btn-group > .btn {
        flex: 1 1 auto;
        text-align: center;
    }
}