﻿/*------------------------------------------------ LAYOUT ------------------------------------------------*/

/* 1) Variables */
:root {
    --bs-primary: #ff5722;
    --bs-secondary: #ffad38;
}

/* 2) Reset + tipografía */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', sans-serif;
    background: #f9f9f9;
    color: #333;
}

/* 3) Navbar */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,.05);
}

.navbar-brand img {
    height: 40px;
}

/* 4) Botón “Volver a la web” (texto) */
.btn-volver {
    display: inline-block;
    padding: .6rem 1.2rem;
    background-color: var(--bs-primary);
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    border-radius: 12px;
    transition: background-color .2s ease;
}

    .btn-volver:hover {
        background-color: #ee8971;
    }

/* 5) Botón “Volver” (icono móvil) */
.btn-volver-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background-color: var(--bs-primary);
    color: #fff;
    border-radius: 50%;
    font-size: 1.2rem;
    transition: background-color .2s, transform .1s;
}

    .btn-volver-icon:hover {
        background-color: #ee8971;
        transform: translateY(-1px);
    }

/* 6) Footer */
.site-footer {
    background-color: #222;
    color: #ccc;
    text-align: center;
    padding: 1rem 0;
    font-size: .875rem;
}

    .site-footer a {
        color: #ccc;
        font-weight: 600;
        text-decoration: none;
        transition: color .2s;
    }

        .site-footer a:visited {
            color: #ccc;
        }

        .site-footer a:hover,
        .site-footer a:focus {
            color: #fff;
            text-decoration: underline;
        }

/* 7) Helpers de espaciado */
.site-content,
.container.site-content {
    padding-top: 2rem;
    padding-bottom: 2rem;
}

/*------------------------------------------------ COMPONENTES ------------------------------------------------*/

/* Botón primario (consolidado) */
.btn-primary {
    background-color: var(--bs-primary);
    border: none;
    border-radius: 8px;
    font-weight: 700;
    color: #fff !important;
    transition: background-color .2s ease;
}

    .btn-primary:hover,
    .btn-primary:focus,
    .btn-primary:active {
        background-color: #ee8971;
        color: #fff !important;
    }

/* Botón warning (consolidado) */
.btn-warning {
    background-color: var(--bs-secondary);
    border: none;
    font-weight: 700;
    color: #fff !important;
    transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

    .btn-warning:hover,
    .btn-warning:focus,
    .btn-warning:active {
        background-color: #ffc738;
        color: #fff !important;
    }

/* Inputs focus (consolidado) */
.form-control:focus,
.form-check-input:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 3px rgba(255,87,34,.15);
}

/* Modal overlay genérico + spinner */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    animation: fadeIn .3s ease forwards;
}

    .modal-overlay.active {
        display: flex;
    }

.modal-content {
    background: #fff;
    padding: 2rem 1.5rem;
    border-radius: 12px;
    text-align: center;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 6px 20px rgba(0,0,0,.2);
}

    .modal-content h2 {
        margin-bottom: 1rem;
        font-size: 1.5rem;
        color: var(--bs-primary);
    }

    .modal-content p {
        margin-bottom: 1.5rem;
        color: #333;
        font-size: 1rem;
    }

.spinner {
    margin: 1.5rem auto 0;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--bs-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Iconos naranja en labels login */
.form-label i.text-primary {
    color: var(--bs-primary) !important;
}

/* Card */
.card.shadow-sm {
    border: none;
    box-shadow: 0 4px 16px rgba(0,0,0,.08);
}

.card .h5,
.card .card-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
}

/* Sub-bloque “Datos de alta” */
.alt-color {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.08);
}

/* Separador de sección */
.section-separator {
    position: relative;
    text-align: center;
    margin: 2.5rem 0 1rem;
}

    .section-separator span {
        position: relative;
        z-index: 1;
        background: #fff;
        padding: 0 1rem;
        color: var(--bs-primary);
        font-weight: 600;
        text-transform: uppercase;
        font-size: .95rem;
        letter-spacing: .5px;
    }

    .section-separator::before {
        content: "";
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 2px;
        background: var(--bs-primary);
        transform: translateY(-50%);
        z-index: 0;
    }

/* Icono en labels */
.form-label i {
    color: var(--bs-primary);
    margin-right: .75rem;
    width: 1em;
    text-align: center;
    vertical-align: middle;
}

/* Resumen validación */
#validationSummary {
    margin-bottom: 1rem;
}

/* Texto previo a checkbox */
.form-description {
    font-size: .85rem;
    color: #555;
    margin: 1.5rem 0;
    line-height: 1.5;
    text-align: center;
}

    .form-description a {
        color: var(--bs-primary);
        font-weight: 600;
        text-decoration: none;
    }

        .form-description a:hover {
            text-decoration: underline;
        }

/* Usuario + logout */
.user-info-container {
    display: inline-flex;
    align-items: center;
    background-color: var(--bs-primary);
    color: #fff;
    padding: .5rem 1rem;
    border-radius: 8px;
    font-weight: 600;
}

    .user-info-container i {
        margin-right: .5rem;
        font-size: 1.2rem;
    }

.btn-link.text-primary,
.logout-button {
    color: var(--bs-primary);
    text-decoration: none;
}

.logout-button {
    background: none;
    border: none;
    font-size: 1.2rem;
    padding: 0;
    cursor: pointer;
}

    .logout-button:hover,
    .btn-link.text-primary:hover {
        color: #ee8971;
        text-decoration: none;
    }

/* Feedback consentimiento */
#consentError {
    margin-top: .25rem;
}

/* Keyframes */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Separador vertical entre Entrega y Recogida */
@media (min-width: 992px) {
    .entrega-recogida > .col-lg-6 + .col-lg-6 {
        border-left: 1px solid rgba(0,0,0,.1);
        padding-left: 1.5rem;
    }

    .entrega-recogida > .col-lg-6 {
        padding-right: 1.5rem;
    }
}

/* ===== Pills / Botones naranja outline (incluye “Limpiar filtros”) ===== */
.btn-outline-orange {
    --gg-orange: var(--bs-secondary); /* puedes cambiar a var(--bs-primary) si prefieres */
    border: 2px solid var(--gg-orange);
    color: var(--gg-orange);
    background-color: #fff;
    font-size: 0.8rem;
    padding: 0.2rem 0.7rem;
    border-radius: 0.4rem;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}

    .btn-outline-orange i {
        color: currentColor;
    }

    /* Hover + mientras está pulsado */
    .btn-outline-orange:hover,
    .btn-outline-orange:active {
        background-color: var(--gg-orange);
        border-color: var(--gg-orange);
        color: #fff;
    }

    /* Quitar halo de foco sin tocar colores */
    .btn-outline-orange:focus {
        box-shadow: none;
        outline: none;
    }

/* Versión toggle con .btn-check (pills) */
.btn-check:checked + .btn-outline-orange {
    background: var(--gg-orange);
    border-color: var(--gg-orange);
    color: #fff;
}

    .btn-check:checked + .btn-outline-orange:hover,
    .btn-check:checked + .btn-outline-orange:focus,
    .btn-check:checked + .btn-outline-orange:active {
        background: var(--gg-orange) !important;
        border-color: var(--gg-orange) !important;
        color: #fff !important;
    }

/* Centrado del grupo de pills */
.tipo-cliente {
    display: flex;
    justify-content: center;
    margin-bottom: 1rem;
}

/* Pills/Badges un poco más grandes (consolidado) */
.badge-lg {
    padding: .5rem .75rem;
    font-size: .95rem;
    border-radius: 9999px;
    font-weight: 700;
    color: #fff !important;
}

/* Chip servicio (consolidado) */
.chip {
    display: inline-flex;
    align-items: center;
    padding: .25rem .6rem;
    border-radius: 9999px;
    font-size: .85rem;
    font-weight: 600;
    background: #f1f3f5;
    color: #333;
}

    .chip i {
        margin-right: .4rem;
    }

/* ===== Responsive móvil utilidades ===== */
@media (max-width: 767.98px) {
    .mobile-card {
        box-shadow: 0 12px 28px rgba(0,0,0,.14) !important;
        border: 1px solid rgba(0,0,0,.08) !important;
        border-radius: 14px !important;
        margin-bottom: 1rem;
    }

    .user-info-container {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .page-container {
        margin-top: 1rem !important;
    }

    .actions-bar {
        margin-bottom: .75rem !important;
    }
}

/* ===== Paginación naranja ===== */
.pagination-orange .page-link {
    border: 1px solid #ffd08a;
    color: #333;
    font-weight: 600;
    border-radius: 8px;
    margin: 0 2px;
    transition: background .15s, color .15s, border-color .15s;
    box-shadow: 0 1px 2px rgba(0,0,0,.04);
    padding: .35rem .55rem;
}

    .pagination-orange .page-link:hover {
        background: var(--bs-secondary);
        color: #fff;
        border-color: var(--bs-secondary);
    }

.pagination-orange .page-item.active .page-link {
    background: var(--bs-primary);
    border-color: var(--bs-primary);
    color: #fff;
}

.pagination-orange .page-item.disabled .page-link {
    background: #f3f3f3;
    color: #999;
    border-color: #eee;
    opacity: .7;
    cursor: default;
}

/* Pager compacto */
.pager-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    flex-wrap: nowrap;
    overflow-x: hidden;
}

.pager-summary {
    white-space: nowrap;
}

.pager-controls {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: nowrap;
}

.page-size-form {
    display: flex;
    align-items: center;
    gap: .5rem;
    white-space: nowrap;
}

.page-size-select {
    min-width: 64px;
}

.pagination-scroll {
    max-width: 100%;
    overflow-x: auto;
}

    .pagination-scroll::-webkit-scrollbar {
        height: 6px;
    }

    .pagination-scroll::-webkit-scrollbar-thumb {
        background: rgba(0,0,0,.15);
        border-radius: 8px;
    }

@media (max-width: 576px) {
    .pager-toolbar {
        flex-wrap: wrap;
    }

    .pager-summary {
        order: 3;
        width: 100%;
        text-align: center;
        margin-top: .25rem;
    }

    .pagination-orange .page-link {
        padding: .3rem .45rem;
        font-size: .85rem;
    }
}

/* ===== Back-to-top ===== */
.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--bs-primary);
    color: #fff !important;
    box-shadow: 0 8px 24px rgba(0,0,0,.18);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s, background .2s;
    text-decoration: none;
}

    .back-to-top:hover {
        background: #ee8971;
        color: #fff !important;
    }

    .back-to-top.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

/* ===== Scroll-top (consolidado, usa primary) ===== */
.scroll-top {
    position: fixed;
    right: 18px;
    bottom: 18px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    outline: none;
    background: var(--bs-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 24px rgba(0,0,0,.22);
    cursor: pointer;
    z-index: 1500;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .18s ease, transform .18s ease, background-color .2s ease;
}

    .scroll-top i {
        font-size: 18px;
        line-height: 1;
    }

    .scroll-top.show {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .scroll-top:hover {
        background: #ee8971;
    }

/* ===== Título de página (consolidado + responsive) ===== */
.page-title {
    text-transform: uppercase;
    font-size: 2rem;
    line-height: 1.15;
}

@media (max-width: 991.98px) {
    .page-title {
        font-size: clamp(20px, 3.6vw, 28px);
    }
}

@media (max-width: 575.98px) {
    .page-title {
        font-size: clamp(18px, 5.2vw, 24px);
        letter-spacing: -0.2px;
        white-space: normal;
        line-height: 1.2;
    }
}

/* ===== Modal Detalle (Bootstrap 3) — consolidado sin conflictos ===== */

/* Diálogo grande + márgenes */
#detalleModal .modal-dialog {
    width: 96vw !important;
    max-width: 1280px !important;
    margin: 2vh auto !important;
}

/* Contenido general */
#detalleModal .modal-content {
    border-radius: 14px;
}

/* Header centrado */
#detalleModal .modal-header {
    border-bottom: 0;
    text-align: center;
}

#detalleModal .modal-title {
    font-weight: 700;
    text-transform: uppercase;
}

/* Cuerpo: sin scroll en desktop, con scroll en móvil */
@media (min-width: 768px) {
    #detalleModal .modal-body {
        max-height: none;
        overflow: visible;
        padding: 16px 20px;
    }
}

@media (max-width: 767px) {
    #detalleModal .modal-body {
        max-height: calc(100vh - 160px);
        overflow-y: auto;
        padding: 16px 20px;
    }
}

/* Inputs readonly activos visualmente */
#detalleModal input[readonly] {
    background-color: #fff;
    cursor: default;
}

/* Separadores dentro del modal */
#detalleModal .section-separator {
    position: relative;
    text-align: center;
    margin: 16px 0 12px;
}

    #detalleModal .section-separator span {
        position: relative;
        z-index: 1;
        background: #fff;
        padding: 0 12px;
        color: var(--bs-primary);
        font-weight: 700;
        text-transform: uppercase;
        font-size: .95rem;
        letter-spacing: .5px;
    }

    #detalleModal .section-separator:before {
        content: "";
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 2px;
        background: var(--bs-primary);
        transform: translateY(-50%);
    }

/* Footer centrado */
#detalleModal .modal-footer {
    border-top: 0;
    text-align: center !important;
    padding-top: 8px;
}

    #detalleModal .modal-footer .btn {
        min-width: 120px;
    }

/* Variante gigante (si se usa la clase adicional) */
.modal.modal-detalle-giant .modal-dialog {
    width: 96vw !important;
    max-width: 1280px !important;
    margin: 2vh auto !important;
}

@media (max-width: 991px) {
    .modal.modal-detalle-giant .modal-dialog {
        width: calc(100vw - 16px) !important;
        max-width: none !important;
        margin: 8px auto !important;
    }
}

.modal.modal-detalle-giant .modal-content {
    max-height: 96vh !important;
    display: flex;
    flex-direction: column;
}

.modal.modal-detalle-giant .modal-body {
    overflow: auto;
    max-height: calc(96vh - 130px) !important;
}

/* ===== HOTFIX: Modal Detalle (BS3) viewport-wide ===== */
#detalleModal.modal .modal-dialog,
.detalle-modal .detalle-modal-dialog {
    width: 96vw !important;
    max-width: 1280px !important;
    margin: 2vh auto !important;
}

@media (max-width: 991px) {
    #detalleModal.modal .modal-dialog,
    .detalle-modal .detalle-modal-dialog {
        width: calc(100vw - 16px) !important;
        max-width: none !important;
        margin: 8px auto !important;
    }
}

#detalleModal.modal .modal-content {
    max-width: none !important;
    width: auto !important;
    border-radius: 14px;
}

@media (min-width: 768px) {
    #detalleModal .modal-body {
        max-height: none !important;
        overflow: visible !important;
        padding: 16px 20px;
    }
}

@media (max-width: 767.98px) {
    #detalleModal .modal-body {
        max-height: calc(100vh - 160px) !important;
        overflow-y: auto !important;
        padding: 16px 20px;
    }
}

/* Centrar paginación en móvil (superior e inferior) */
@media (max-width: 767.98px) {
    .pager-toolbar {
        justify-content: center;
        gap: .5rem;
    }

    .pager-controls {
        width: 100%;
        justify-content: center;
    }

    .pagination-scroll {
        width: 100%;
        display: flex;
        justify-content: center;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

        .pagination-scroll ul.pagination {
            margin: 0 auto;
            white-space: nowrap;
        }
}

/* Ocultar la burbuja cuando hay un modal abierto */
.modal-open .scroll-top {
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    pointer-events: none;
}

/* ===== Overlay de carga global ===== */
.app-loading {
    position: fixed;
    inset: 0;
    z-index: 4000;
    background: rgba(255,255,255,.92);
    display: none;
    align-items: center;
    justify-content: center;
    -webkit-backdrop-filter: blur(1px);
    backdrop-filter: blur(1px);
}

    .app-loading.show {
        display: flex;
    }

    .app-loading .loader {
        position: relative;
        width: 88px;
        height: 88px;
    }

    .app-loading .ring {
        box-sizing: border-box;
        width: 100%;
        height: 100%;
        border: 6px solid #ffe1d7;
        border-top-color: var(--bs-primary);
        border-radius: 50%;
        animation: spin 1s linear infinite;
        box-shadow: 0 2px 8px rgba(0,0,0,.06) inset;
    }

    .app-loading .logo {
        position: absolute;
        inset: 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        .app-loading .logo img {
            width: 36px;
            height: 36px;
            object-fit: contain;
        }

    .modal-open .scroll-top,
    .app-loading.show ~ .scroll-top {
        opacity: 0;
        visibility: hidden;
        transform: translateY(8px);
        pointer-events: none;
    }

/* ===== Spinner del modal de bienvenida (login) ===== */
#welcomeModal .modal-content {
    border-radius: 14px;
}

#welcomeModal .loader {
    position: relative;
    width: 88px;
    height: 88px;
    margin: 0 auto;
}

    #welcomeModal .loader .ring {
        box-sizing: border-box;
        width: 100%;
        height: 100%;
        border: 6px solid #ffe1d7;
        border-top-color: var(--bs-primary);
        border-radius: 50%;
        animation: spin 1s linear infinite;
        box-shadow: inset 0 2px 8px rgba(0,0,0,.06);
    }

    #welcomeModal .loader .logo {
        position: absolute;
        inset: 0;
        display: flex;
        align-items: center;
        justify-content: center;
    }

        #welcomeModal .loader .logo img {
            width: 36px;
            height: 36px;
            object-fit: contain;
        }

/* Cabecera naranja, texto blanco, centrado */
.page-title-wrap {
    background: #ffcc52;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 1.25rem;
    border-radius: .5rem;
}

    .page-title-wrap .page-title {
        color: inherit;
    }

.card > .page-title-wrap {
    border-top-left-radius: .5rem;
    border-top-right-radius: .5rem;
}

@media (max-width: 576px) {
    .page-title-wrap {
        padding: .85rem 1rem;
    }
}

/* ================================
   Tabla con cabecera naranja
   ================================ */

.table-head-orange {
    border-collapse: separate;
    border-spacing: 0;
    border-radius: .5rem;
    overflow: hidden;
}

    .table-head-orange thead th {
        background: #ff7a00;
        color: #fff;
        text-align: center;
        vertical-align: middle;
        border-bottom: none;
        white-space: nowrap;
        padding-top: .85rem;
        padding-bottom: .85rem;
    }

        .table-head-orange thead th:first-child {
            border-top-left-radius: .5rem;
        }

        .table-head-orange thead th:last-child {
            border-top-right-radius: .5rem;
        }

    .table-head-orange thead tr {
        box-shadow: inset 0 -1px 0 rgba(255,255,255,.25);
    }

    .table-head-orange thead th.text-end {
        text-align: right;
    }

    .table-head-orange tbody tr:hover {
        background: rgba(255,122,0,.06);
    }

/* Spinner local de la tabla */
#gridHost .card.position-relative {
    position: relative;
}

.table-loading {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.65);
    z-index: 5;
    border-radius: .5rem;
}

    .table-loading.show {
        display: flex;
    }

    .table-loading .table-loading-inner {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 64px;
        height: 64px;
    }

    .table-loading .ring {
        width: 48px;
        height: 48px;
        border: 4px solid rgba(0,0,0,.1);
        border-left-color: #ff7a00;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }

/* Estética del checkbox en la toolbar */
.pager-toolbar .form-check-input {
    margin: 0;
    cursor: pointer;
}

.pager-toolbar .form-check-label span {
    user-select: none;
}

/* Checkbox naranja */
.chk-orange {
    accent-color: #ff7a00;
}

#chkFinalizadas {
    accent-color: #ff7a00 !important;
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #ff7a00;
    border-radius: 4px;
    position: relative;
    cursor: pointer;
    transition: background-color .15s, border-color .15s;
}

    #chkFinalizadas:checked {
        background-color: #ff7a00;
        border-color: #ff7a00;
    }

        #chkFinalizadas:checked::after {
            content: '';
            position: absolute;
            top: 2px;
            left: 5px;
            width: 4px;
            height: 8px;
            border: solid white;
            border-width: 0 2px 2px 0;
            transform: rotate(45deg);
        }

/* ===== Override: modal detalle como panel a 1 viewport en móvil ===== */
@media (max-width: 767.98px) {
    #detalleModal.modal.modal-detalle-giant .modal-dialog {
        width: 100vw !important;
        height: 100vh !important;
        max-width: none !important;
        margin: 0 !important;
    }

    #detalleModal.modal.modal-detalle-giant .modal-content {
        height: 100vh !important;
        border-radius: 0 !important;
        display: flex !important;
        flex-direction: column !important;
    }

    #detalleModal.modal.modal-detalle-giant .modal-body {
        flex: 1 1 auto !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
    }
}

/* Desktop/tablet: altura cómoda con scroll interno si hiciera falta */
@media (min-width: 768px) {
    #detalleModal.modal.modal-detalle-giant .modal-dialog {
        width: 96vw !important;
        max-width: 1280px !important;
        margin: 2vh auto !important;
    }

    #detalleModal.modal.modal-detalle-giant .modal-content {
        height: 96vh !important;
        display: flex !important;
        flex-direction: column !important;
    }

    #detalleModal.modal.modal-detalle-giant .modal-body {
        flex: 1 1 auto !important;
        overflow-y: auto !important;
    }
}

/* Contenedor más ancho para la página de estados */
.page-container-wide {
    width: 100%;
    max-width: 1800px;
    margin: 0 auto;
}

/* Layout vertical: título + filtro en cada th */
.table-head-orange thead th {
    vertical-align: middle;
}

.table-head-orange .th-filter-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

    .table-head-orange .th-filter-wrapper .btn-sort {
        font-weight: 600;
        text-decoration: underline;
        padding: 0;
    }

/* Inputs y selects de filtros */
.table-head-orange .filter-input,
.table-head-orange .filter-select {
    font-size: 0.75rem;
    padding: 0.15rem 0.35rem;
    height: 1.8rem;
    color: #333 !important;
    background-color: #fff !important;
}

    .table-head-orange .filter-input::placeholder {
        color: #999;
    }

/* Layout amplio opcional */
body.layout-wide .main-shell {
    width: 100%;
    max-width: 1800px;
    margin: 0 auto;
}

/* Barra de título con grid para centrar el texto */
.title-bar-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr; /* centro fijo, derecha para el combo */
    align-items: center;
}

/* El título va siempre en la columna central y centrado */
.title-bar-center {
    grid-column: 2;
    justify-self: center;
}

/* El selector se alinea a la derecha */
.title-bar-right {
    grid-column: 3;
    justify-self: end;
}

/* Label "Empresa" más grande y en blanco */
.empresa-label {
    font-size: 0.9rem; /* un poco más pequeña que el h1 */
    font-weight: 600;
    color: #ffffff;
    text-transform: uppercase;
}

/* En móvil apilamos título y combo uno debajo de otro */
@media (max-width: 767.98px) {
    .title-bar-grid {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .title-bar-right {
        margin-top: 0.5rem;
    }
}

.empresa-selector {
    font-size: .9rem;
}

.empresa-label {
    font-weight: 600;
    color: #fff; /* o el color que uses en la pastilla superior */
}

.empresa-select-label {
    color: #000 !important;
    font-weight: 600;
    font-size: 0.9rem;
}

.empresa-select-control {
    min-width: 180px; /* o 200px si quieres más */
}
