:root {
    --background: var(--color-bg);
    --surface: var(--color-surface);
    --surface-soft: var(--color-surface-soft);
    --panel-surface: var(--card-surface);
    --primary: var(--color-primary);
    --primary-dark: var(--color-primary-hover);
    --secondary: var(--color-secondary);
    --secondary-dark: var(--color-secondary-hover);
    --accent: var(--color-accent);
    --text: var(--color-text);
    --muted: var(--color-text-secondary);
    --line: var(--color-border);
    --white: var(--color-card);
    --success: var(--state-success);
    --warning: var(--state-warning);
    --danger: var(--state-danger);
    --info: var(--state-info);
    --shadow: var(--shadow-card);
    --radius: var(--radius-lg);
    --title-scale: 1;
    --heading-font-size-adjust: 1;
    --heading-font-weight: 700;
    --card-padding: 22px;
    --card-gap: 16px;
    --section-gap: 24px;
    --component-gap: 14px;
    --safe-area-top: env(safe-area-inset-top, 0px);
    --safe-area-right: env(safe-area-inset-right, 0px);
    --safe-area-bottom: env(safe-area-inset-bottom, 0px);
    --safe-area-left: env(safe-area-inset-left, 0px);
    --responsive-shell-padding: 1.5rem;
    --responsive-main-padding: 1.5rem;
    --responsive-section-gap: var(--section-gap);
    --responsive-component-gap: var(--component-gap);
}

/* Efectivo operativo acumulado: acción compacta y retiro en modal. */
.summary-page.summary-page-redesigned .summary-operational-weekly-header {
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    gap: 16px !important;
    width: 100% !important;
}

.summary-page.summary-page-redesigned .summary-operational-weekly-header .summary-block-title-group {
    min-width: 0 !important;
    flex: 1 1 auto !important;
}

.summary-page.summary-page-redesigned .summary-operational-weekly-total {
    min-height: 0 !important;
}

.summary-page.summary-page-redesigned .operational-cash-withdrawal-trigger {
    flex: 0 0 auto !important;
    align-self: flex-start !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    min-height: 38px !important;
    margin: 0 !important;
    padding: 0 14px !important;
    white-space: nowrap !important;
}

.summary-page.summary-page-redesigned .operational-cash-withdrawal-trigger i {
    font-size: 0.78rem !important;
}

.operational-cash-withdrawal-modal .modal-dialog {
    width: min(100%, 520px) !important;
    height: auto !important;
    max-height: min(90vh, 720px) !important;
}

.operational-cash-withdrawal-modal .modal-body {
    flex: 0 1 auto !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

.operational-cash-withdrawal-available {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 16px;
    padding: 14px 16px;
    border: 1px solid rgba(35, 168, 92, 0.24);
    border-radius: 14px;
    background: rgba(242, 255, 248, 0.9);
}

.operational-cash-withdrawal-available span {
    color: #4D6A5B;
    font-size: 0.82rem;
    font-weight: 600;
}

.operational-cash-withdrawal-available strong {
    color: #006B3F;
    font-size: 1.45rem;
    line-height: 1;
    white-space: nowrap;
}

.operational-cash-withdrawal-helper {
    margin: 0 0 18px !important;
    line-height: 1.35 !important;
}

.operational-cash-withdrawal-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.operational-cash-withdrawal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

@media (min-width: 768px) and (max-width: 899px) and (orientation: portrait) {
    .summary-page.summary-page-redesigned .summary-operational-weekly-header {
        flex-wrap: wrap !important;
    }

    .summary-page.summary-page-redesigned .operational-cash-withdrawal-trigger {
        margin-left: auto !important;
    }
}

@media (max-width: 767px) {
    .summary-page.summary-page-redesigned .summary-operational-weekly-header {
        align-items: flex-start !important;
        flex-wrap: nowrap !important;
        gap: 12px !important;
    }

    .summary-page.summary-page-redesigned .summary-operational-weekly-header .summary-block-title-group {
        width: auto !important;
        flex: 1 1 auto !important;
    }

    .summary-page.summary-page-redesigned .operational-cash-withdrawal-trigger {
        flex: 0 0 42px !important;
        width: 42px !important;
        min-width: 42px !important;
        min-height: 42px !important;
        padding: 0 !important;
        border-radius: 12px !important;
        gap: 0 !important;
    }

    .summary-page.summary-page-redesigned .operational-cash-withdrawal-trigger span {
        display: none !important;
    }

    .operational-cash-withdrawal-modal {
        z-index: 1300 !important;
        width: 100% !important;
        padding: 10px !important;
        box-sizing: border-box !important;
    }

    .operational-cash-withdrawal-modal .modal-dialog {
        width: min(100%, 520px) !important;
        max-width: 100% !important;
        height: auto !important;
        max-height: 90vh !important;
        max-height: 90dvh !important;
        border-radius: 20px !important;
        margin: 0 auto !important;
        box-sizing: border-box !important;
    }

    .operational-cash-withdrawal-modal .modal-header {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        flex-wrap: nowrap !important;
        gap: 8px !important;
        padding: 16px 18px 14px !important;
    }

    .operational-cash-withdrawal-modal .modal-header h3 {
        min-width: 0 !important;
        flex: 1 1 auto !important;
        max-width: none !important;
        margin: 0 !important;
        font-size: 17px !important;
        font-weight: 700 !important;
        line-height: 1.2 !important;
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: clip !important;
        overflow-wrap: normal !important;
        word-break: normal !important;
    }

    .operational-cash-withdrawal-modal .modal-close-btn {
        position: static !important;
        flex: 0 0 40px !important;
        width: 40px !important;
        min-width: 40px !important;
        height: 40px !important;
        margin: -2px 0 0 !important;
    }

    .operational-cash-withdrawal-modal .modal-body {
        padding: 16px 18px 18px !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
    }

    .operational-cash-withdrawal-fields {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    .operational-cash-withdrawal-actions {
        flex-direction: column-reverse;
    }

    .operational-cash-withdrawal-actions .btn {
        width: 100%;
        min-height: 44px;
    }
}

/* Estado final del boton, despues de todas las reglas responsive heredadas. */
body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:not(:disabled) {
    background: #db3ca2 !important;
    color: #fff !important;
    cursor: pointer !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:not(:disabled):hover {
    background: #c92f95 !important;
    color: #fff !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:disabled,
body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:disabled:hover {
    border-color: #e1e5eb !important;
    background: #edf0f3 !important;
    color: #8b929c !important;
    cursor: default !important;
    opacity: 1 !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:not(:disabled) {
    background: #db3ca2 !important;
    color: #fff !important;
    cursor: pointer !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:not(:disabled):hover {
    background: #c92f95 !important;
    color: #fff !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:disabled,
body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filter-field--actions > .dashboard-pending-orders-clear-action:disabled:hover {
    border-color: #e1e5eb !important;
    background: #edf0f3 !important;
    color: #8b929c !important;
    cursor: default !important;
    opacity: 1 !important;
}

/* /admin/dashboard: accion de limpieza en flujo normal, debajo de los filtros. */
body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filters-actions {
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    width: 100% !important;
    margin: 6px 0 8px !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filters-actions .dashboard-pending-orders-clear-action {
    position: static !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    flex: 0 0 auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 2px 0 !important;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #8b929c !important;
    font-size: 0.76rem !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    cursor: default !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filters-actions .dashboard-pending-orders-clear-action:not(:disabled) {
    color: #db3ca2 !important;
    cursor: pointer !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filters-actions .dashboard-pending-orders-clear-action:not(:disabled):hover {
    background: transparent !important;
    color: #c92f95 !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-filters-actions .dashboard-pending-orders-clear-action:disabled:hover {
    background: transparent !important;
    color: #8b929c !important;
}

/* Compatibilidad con el bloque antiguo: el boton ya no participa en la grilla. */
body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-clear-action {
    position: static !important;
    z-index: 22 !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    min-height: 0 !important;
    height: auto !important;
    margin: 0 !important;
    padding: 2px 0 !important;
    border: 0 !important;
    background: transparent !important;
    color: #8b929c !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 0.76rem !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    box-sizing: border-box !important;
    cursor: default !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-clear-action:not(:disabled) {
    color: #db3ca2 !important;
    cursor: pointer !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-clear-action:not(:disabled):hover {
    background: transparent !important;
    color: #c92f95 !important;
}

body:has(.dashboard-page-shell) #reportDelayedOrdersModal.dashboard-pending-orders-modal .dashboard-pending-orders-clear-action:disabled:hover {
    background: transparent !important;
    color: #8b929c !important;
}

/* Reporte de cierre diario: documento independiente del dashboard. */
.daily-closure-report-modal .modal-dialog {
    width: min(96vw, 980px) !important;
    height: min(90vh, 900px) !important;
    max-height: 90vh !important;
}

.daily-closure-report-modal .daily-closure-report-modal-header {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.daily-closure-report-modal .daily-closure-report-modal-header h3 {
    min-width: 0 !important;
    margin: 0 !important;
}

.daily-closure-report-modal .daily-closure-report-modal-body {
    padding: 20px !important;
    background: #eef3f8;
}

.daily-closure-report-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 12px;
}

.daily-closure-report-actions .btn {
    min-height: 38px;
}

.daily-closure-report-feedback {
    margin: 0 0 14px !important;
}

.daily-closure-report-feedback[data-tone="error"] { color: #b42318; }
.daily-closure-report-feedback[data-tone="success"] { color: #087443; }

.daily-closure-report-preview {
    overflow: auto;
    padding: 18px;
    border: 1px solid #d6e0eb;
    border-radius: 16px;
    background: #dfe8f0;
}

.daily-closure-report-preview-stage {
    position: relative;
    width: 794px;
    margin: 0 auto;
}

.daily-closure-report-preview-stage > .daily-closure-report {
    position: absolute;
    top: 0;
    left: 0;
    transform: scale(var(--daily-report-preview-scale, 1));
    transform-origin: top left;
}

.daily-closure-report,
.daily-closure-report * {
    box-sizing: border-box;
}

.daily-closure-report {
    width: 794px;
    max-width: none;
    margin: 0 auto;
    padding: 42px;
    color: #1d2d44;
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 12px;
    line-height: 1.4;
    box-shadow: 0 10px 28px rgba(24, 53, 87, .12);
}

.daily-report-header {
    display: grid;
    grid-template-columns: 105px minmax(0, 1fr) auto;
    gap: 20px;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 3px solid #1c4f86;
}

.daily-report-logo { width: 100%; max-height: 58px; object-fit: contain; object-position: left center; }
.daily-report-heading p, .daily-report-heading h2, .daily-report-heading span { margin: 0; }
.daily-report-heading p { color: #4173a8; font-size: 10px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.daily-report-heading h2 { margin: 2px 0 4px; color: #173f6c; font-size: 24px; line-height: 1.1; }
.daily-report-heading span, .daily-report-issued { color: #62758b; }
.daily-report-issued { text-align: right; font-size: 10px; }
.daily-report-issued span { display: block; text-transform: uppercase; letter-spacing: .08em; }
.daily-report-issued strong { color: #274769; font-size: 11px; }

.daily-report-section { margin-top: 26px; }
.daily-report-section h3 { margin: 0 0 10px; color: #173f6c; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; }
.daily-report-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.daily-report-kpis > div { min-height: 78px; padding: 13px; border: 1px solid #dce6ef; border-radius: 8px; background: #f8fafc; }
.daily-report-kpis span { display: block; color: #61758a; font-size: 10px; }
.daily-report-kpis strong { display: block; margin-top: 8px; color: #193f6c; font-size: 16px; line-height: 1.1; }
.daily-closure-report .is-positive { color: #087443 !important; }
.daily-closure-report .is-expense { color: #b42318 !important; }

.daily-report-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.daily-report-table th, .daily-report-table td { padding: 9px 10px; border-bottom: 1px solid #dfe7ef; text-align: left; }
.daily-report-table th:last-child, .daily-report-table td:last-child { text-align: right; white-space: nowrap; }
.daily-report-table thead th { color: #49657f; font-size: 10px; letter-spacing: .04em; text-transform: uppercase; background: #f1f5f9; }
.daily-report-table tfoot th { color: #173f6c; border-top: 2px solid #87a8c8; border-bottom: 0; }
.daily-report-empty, .daily-report-context { margin: 0; color: #61758a; }
.daily-report-extra-expenses { margin: 10px 0 0; color: #61758a; font-size: 11px; }

.daily-report-two-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.daily-report-two-columns .daily-report-section { padding: 16px; border: 1px solid #dce6ef; border-radius: 8px; background: #fbfcfd; }
.daily-report-two-columns .daily-report-section h3 { margin-bottom: 12px; }
.daily-report-definition-list { margin: 0; }
.daily-report-definition-list > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid #e7edf3; }
.daily-report-definition-list > div:last-child { border-bottom: 0; }
.daily-report-definition-list dt { color: #60758c; }
.daily-report-definition-list dd { margin: 0; color: #1d3857; font-weight: 700; text-align: right; }
.daily-report-reconciliation { margin-top: 8px; }
.daily-report-reconciliation .daily-report-total { margin-top: 4px; padding-top: 10px; border-top: 2px solid #87a8c8; }
.daily-report-reconciliation .daily-report-total dt, .daily-report-reconciliation .daily-report-total dd { color: #173f6c; font-size: 13px; }
.daily-report-status { display: inline-block; padding: 3px 7px; border-radius: 999px; font-size: 10px; }
.daily-report-status.is-positive { background: #e5f7ed; }
.daily-report-status.is-warning { color: #915f00; background: #fff3d6; }
.daily-report-status.is-neutral { color: #52677c; background: #edf2f6; }
.daily-report-observations { padding: 14px 16px; border-left: 3px solid #6c91b7; background: #f5f8fb; }
.daily-report-observations p { margin: 0; }
.daily-report-footer { margin-top: 30px; padding-top: 14px; border-top: 1px solid #dfe7ef; color: #66798e; font-size: 10px; text-align: center; }

.daily-report-export-stage { position: fixed; top: 0; left: -10000px; width: 794px; background: #fff; }
.daily-closure-report--export { width: 794px !important; max-width: none !important; margin: 0 !important; box-shadow: none !important; }

@media (max-width: 767px) {
    .daily-closure-report-modal .modal-dialog { width: calc(100vw - 20px) !important; max-height: 90dvh !important; }
    .daily-closure-report-modal .daily-closure-report-modal-header { flex-wrap: nowrap !important; align-items: flex-start !important; }
    .daily-closure-report-modal .daily-closure-report-modal-header h3 { flex: 1 1 auto !important; font-size: 17px !important; line-height: 1.2 !important; white-space: normal !important; overflow: visible !important; text-overflow: clip !important; }
    .daily-closure-report-modal .modal-close-btn { position: static !important; flex: 0 0 40px !important; width: 40px !important; height: 40px !important; margin: 0 !important; }
    .daily-closure-report-modal .daily-closure-report-modal-body { padding: 12px !important; }
    .daily-closure-report-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
    .daily-closure-report-actions .btn { width: 100%; padding-inline: 8px; font-size: 12px; }
    .daily-closure-report-preview { padding: 10px; }
}

/* Informe de cierre: composición editorial para vista previa y A4. */
.daily-closure-report { padding: 38px !important; font-size: 12px !important; box-shadow: none !important; }
.daily-report-header { grid-template-columns: 128px 1px minmax(0, 1fr) !important; gap: 22px !important; padding-bottom: 24px !important; border-bottom: 1px solid #d5e1ed !important; }
.daily-report-logo { max-height: 72px !important; }
.daily-report-header-rule { align-self: stretch; background: #c9d9e8; }
.daily-report-heading h2 { margin: 0 0 7px !important; color: #163e6c !important; font-size: 28px !important; letter-spacing: -.02em; }
.daily-report-heading p { margin: 0 0 5px !important; color: #315f8f !important; font-size: 13px !important; font-weight: 700; text-transform: none !important; letter-spacing: 0 !important; }
.daily-report-heading span { color: #72849a; font-size: 11px; }
.daily-report-kpis { margin-top: 26px; }
.daily-report-kpi { display: flex; align-items: center; gap: 11px; min-height: 96px !important; padding: 14px 16px !important; border: 1px solid transparent !important; border-radius: 14px !important; background: #f7fafc !important; }
.daily-report-kpi > div { display: flex; min-width: 0; flex-direction: column; justify-content: center; }
.daily-report-kpi i { display: grid; width: 34px; height: 34px; place-items: center; flex: 0 0 34px; border-radius: 50%; font-size: 14px; }
.daily-report-kpi span { display: block; color: #63788e; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.daily-report-kpi strong { margin: 5px 0 4px !important; font-size: 18px !important; }
.daily-report-kpi small { color: #71849a; font-size: 10px; }
.daily-report-kpi.is-income { background: #eefaf3 !important; border-color: #d8eedf !important; }.daily-report-kpi.is-income i { color: #11804d; background: #d9f3e4; }
.daily-report-kpi.is-expense { background: #fff4f5 !important; border-color: #f2dfe2 !important; }.daily-report-kpi.is-expense i { color: #bc3f50; background: #fde0e5; }.daily-report-kpi.is-expense strong { color: #b42335 !important; }
.daily-report-kpi.is-result { background: #f0f6fd !important; border-color: #d9e7f5 !important; }.daily-report-kpi.is-result i { color: #2f68a0; background: #dbeafa; }
.daily-report-kpi.is-operational { background: #f0faf5 !important; border-color: #d8eee1 !important; }.daily-report-kpi.is-operational i { color: #188357; background: #d9f2e4; }.daily-report-kpi.is-operational strong { color: #087443 !important; }
.daily-report-split, .daily-report-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 24px; }
.daily-report-card, .daily-report-cash-control { margin: 0 !important; padding: 18px !important; border: 1px solid #dfe8f1; border-radius: 14px; background: #fff; }
.daily-report-card > header, .daily-report-cash-control > header { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 14px; }
.daily-report-card > header > i, .daily-report-cash-control > header > i { display: grid; width: 30px; height: 30px; place-items: center; border-radius: 9px; color: #316a9e; background: #edf5fc; }
.daily-report-card h3, .daily-report-cash-control h3 { margin: 0 0 2px !important; color: #1c416c !important; font-size: 14px !important; letter-spacing: 0 !important; text-transform: none !important; }
.daily-report-card header p, .daily-report-cash-control header p { margin: 0; color: #73869a; font-size: 10px; }
.daily-report-table { font-size: 10.5px; }.daily-report-table th, .daily-report-table td { padding: 8px 7px !important; }.daily-report-table td:first-child i { width: 15px; color: #527da7; }.daily-report-table thead th { background: #f3f7fb !important; }.daily-report-table tfoot th { background: #f8fafc; }
.daily-report-cash-control { margin-top: 24px !important; background: #fbfdff; }.daily-report-cash-panels { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }.daily-report-cash-panel { padding: 16px; border-radius: 12px; }.daily-report-cash-panel h4 { margin: 0 0 10px; color: #294b70; font-size: 13px; }.daily-report-cash-panel.is-cashbox { background: #fffaf0; border: 1px solid #f2e6c7; }.daily-report-cash-panel.is-operational { background: #f1f7fd; border: 1px solid #dceaf7; }.daily-report-cash-panel dl { margin: 0; }.daily-report-cash-panel dl > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid rgba(90, 120, 150, .13); }.daily-report-cash-panel dt { color: #687e94; }.daily-report-cash-panel dd { margin: 0; color: #213f60; font-weight: 700; text-align: right; }.daily-report-balance { margin-top: 5px; padding-top: 10px !important; border-top: 2px solid #8ab3d9 !important; }.daily-report-balance dt, .daily-report-balance dd { color: #124d80 !important; font-size: 13px; }
.daily-report-movements { margin: 0; padding: 0; list-style: none; }.daily-report-movements li { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; gap: 9px; align-items: center; padding: 9px 0; border-bottom: 1px solid #e9eff5; }.daily-report-movements li:last-child { border-bottom: 0; }.daily-report-movements time { color: #5c7893; font-weight: 700; }.daily-report-movements span { min-width: 0; }.daily-report-movements b, .daily-report-movements small { display: block; }.daily-report-movements small { overflow: hidden; color: #74879a; text-overflow: ellipsis; white-space: nowrap; }.daily-report-movements strong { white-space: nowrap; }.daily-report-observation-copy { display: grid; gap: 6px; padding: 13px; border-radius: 10px; color: #294967; background: #f3f8fc; }.daily-report-observation-copy span { color: #71849a; }
.daily-report-footer { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-top: 24px !important; padding-top: 16px !important; text-align: left !important; }.daily-report-footer div { display: grid; gap: 3px; }.daily-report-footer span { color: #72849a; }.daily-report-footer > strong { color: #536d87; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.daily-report-cash-panel h4 { display: flex; align-items: center; gap: 8px; }.daily-report-cash-panel h4 i { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 50%; color: #b87906; background: #ffedbd; }.daily-report-cash-panel.is-operational h4 i { color: #127451; background: #d8f2e6; }.daily-report-cash-status { display: flex; align-items: center; gap: 10px; margin-top: 13px; padding: 11px; border-radius: 10px; color: #8a650d; background: #fff6da; }.daily-report-cash-status.is-complete { color: #087443; background: #e8f8ed; }.daily-report-cash-status > i { display: grid; width: 29px; height: 29px; place-items: center; flex: 0 0 29px; border-radius: 50%; color: #fff; background: #d19a18; }.daily-report-cash-status.is-complete > i { background: #35b96e; }.daily-report-cash-status span { display: grid; gap: 2px; }.daily-report-cash-status small { color: currentColor; opacity: .82; }
.daily-report-movements li { grid-template-columns: 50px 10px minmax(0, 1fr) auto !important; }.daily-report-movements time { padding: 7px 5px; border-radius: 9px; color: #27639d; background: #eef7ff; text-align: center; }.daily-report-movement-dot { width: 10px; height: 10px; border-radius: 50%; background: #2dc978; }.daily-report-movement-dot.is-withdrawal { background: #f7ba20; }.daily-report-observation-copy { grid-template-columns: 32px minmax(0, 1fr); align-items: center; color: #087443; background: #e9f8ee; }.daily-report-observation-copy > i { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 50%; color: #fff; background: #39ba70; }.daily-report-observation-copy span { display: grid; gap: 3px; }.daily-report-observation-copy small { color: #3c6971; }

.daily-report-operational-week { margin-top: 14px; padding: 15px; border: 1px solid #dcefe4; border-radius: 12px; background: #f2fbf6; }
.daily-report-operational-week-header { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 12px; }
.daily-report-operational-week-header h4 { margin: 0 0 2px; color: #1f5f48; font-size: 13px; }
.daily-report-operational-week-header p { margin: 0; color: #6b847b; font-size: 10px; }
.daily-report-operational-week-header > strong { color: #087443; font-size: 18px; white-space: nowrap; }
.daily-report-operational-week-layout { display: grid; grid-template-columns: 155px minmax(0, 1fr); gap: 12px; align-items: stretch; }
.daily-report-operational-week-balance { display: flex; min-height: 110px; flex-direction: column; justify-content: center; padding: 14px; border: 1px solid #d8ece0; border-radius: 10px; background: #fff; }
.daily-report-operational-week-balance span { color: #56756b; font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.daily-report-operational-week-balance strong { margin: 6px 0 4px; color: #087443; font-size: 23px; line-height: 1; }
.daily-report-operational-week-balance small { color: #71877f; font-size: 9px; line-height: 1.35; }
.daily-report-operational-week-days { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.daily-report-operational-day { display: flex; min-width: 0; min-height: 51px; justify-content: space-between; gap: 8px; align-items: center; padding: 9px 10px; border: 1px solid #dbe6ee; border-radius: 9px; background: #fff; }
.daily-report-operational-day.is-current { border-color: #8fdbae; background: #f4fff8; box-shadow: inset 0 0 0 1px rgba(64, 190, 112, .12); }
.daily-report-operational-day > div { display: grid; gap: 1px; }
.daily-report-operational-day b { color: #244767; font-size: 10px; }
.daily-report-operational-day span { color: #7a8d9e; font-size: 9px; }
.daily-report-operational-day > strong { font-size: 11px; white-space: nowrap; }
.daily-report-operational-week footer { display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; padding-top: 9px; border-top: 1px solid #dcebe2; color: #60776f; font-size: 9px; }
.daily-report-operational-week footer b { color: #24674f; white-space: nowrap; }

.daily-report-export-stage { width: 794px !important; }.daily-closure-report--export { width: 794px !important; padding: 38px !important; }
@media (max-width: 767px) { .daily-closure-report-actions { grid-template-columns: 1fr !important; } }

/* Responsive foundation / Tablet-first                                       */
/* -------------------------------------------------------------------------- */
/* Breakpoints de referencia obligatoria para cambios futuros:
   - Mobile: hasta 575px
   - Tablet vertical: 576px a 899px
   - Tablet horizontal: 900px a 1199px
   - Desktop: 1200px+

   Nota:
   - Esta base convive con media queries historicas y con `tablet-app-mode`.
   - No reemplaza la logica visual existente; solo normaliza contenedores,
     paddings, gaps y prevencion de overflow horizontal.
   - Antes de agregar nuevos ajustes por pantalla, reutilizar estos rangos.
*/

html,
body,
.dashboard-frame,
.dashboard-shell,
.app-layout,
.dashboard-main,
.main-content,
.content-area,
.page-content,
.page-section,
.page-shell,
.responsive-grid,
.form-grid,
.order-form-grid,
.summary-grid,
.summary-two-columns,
.cards-grid,
.dashboard-grid,
.admin-grid,
.admin-actions-grid,
.general-summary-grid,
.reports-kpi-grid,
.third-party-metrics-grid,
.content-card,
.card,
.table-card,
.modal-dialog,
.modal-content,
.large-modal,
.history-modal.modal-content {
    min-width: 0;
    max-width: 100%;
}

.dashboard-frame {
    padding: var(--responsive-shell-padding);
}

.dashboard-main,
.main-content {
    padding: var(--responsive-main-padding);
}

.content-area,
.page-content,
.page-section,
.page-shell,
.responsive-grid,
.form-grid,
.order-form-grid,
.summary-grid,
.summary-two-columns,
.cards-grid,
.dashboard-grid,
.admin-grid,
.admin-actions-grid,
.general-summary-grid,
.reports-kpi-grid,
.third-party-metrics-grid {
    gap: var(--responsive-section-gap);
}

.content-card,
.card,
.table-card {
    min-width: 0;
}

.table-wrapper,
.table-scroll-area,
.modal-body,
.modal-scroll-area,
.client-search-shell,
.mobile-more-sheet {
    max-width: 100%;
    box-sizing: border-box;
}

img,
svg,
video,
canvas,
iframe {
    max-width: 100%;
}

/* TODO responsive-audit:
   Todavia existen reglas por modulo y toggles visuales con `tablet-app-mode`.
   Antes de refactorizar JS o eliminar vistas duplicadas, consolidar primero
   estos cuatro rangos en pantallas reales. */

@media (min-width: 1200px) {
    :root {
        --responsive-shell-padding: 1.5rem;
        --responsive-main-padding: 1.5rem;
        --responsive-section-gap: 24px;
        --responsive-component-gap: 14px;
    }
}

.third-mobile-section-switcher {
    display: none;
}

@media (max-width: 767px) {
    .third-mobile-section-switcher {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 8px !important;
        width: 100% !important;
        padding: 6px !important;
        margin: 12px 0 14px !important;
        border-radius: 18px !important;
        border: 1px solid rgba(180, 207, 221, 0.72) !important;
        background: rgba(255, 255, 255, 0.88) !important;
        box-shadow: 0 10px 24px rgba(74, 88, 153, 0.08) !important;
    }

    .third-mobile-switch-btn {
        min-height: 42px !important;
        border-radius: 14px !important;
        border: 1px solid rgba(180, 207, 221, 0.72) !important;
        background: #fff !important;
        color: var(--primary) !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        padding: 0 12px !important;
        font-size: 0.9rem !important;
        line-height: 1 !important;
        font-weight: 700 !important;
        white-space: nowrap !important;
    }

    .third-mobile-switch-btn.is-active,
    .third-mobile-switch-btn[aria-pressed="true"] {
        background: var(--primary) !important;
        border-color: var(--primary) !important;
        color: #fff !important;
        box-shadow: 0 10px 20px rgba(74, 88, 153, 0.16) !important;
    }

    .third-mobile-switch-btn i {
        font-size: 0.86rem !important;
    }

    body.third-mobile-tab-register [data-third-mobile-panel="register"] {
        display: block !important;
    }

    body.third-mobile-tab-register [data-third-mobile-panel="records"] {
        display: none !important;
    }

    body.third-mobile-tab-records [data-third-mobile-panel="register"] {
        display: none !important;
    }

    body.third-mobile-tab-records [data-third-mobile-panel="records"] {
        display: block !important;
    }
}

@media (min-width: 900px) and (max-width: 1199px) and (orientation: landscape) {
  .order-operational-load-card.is-medium .order-operational-load-metrics {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.75fr) minmax(130px, 1.35fr) !important;
  }

  .order-operational-load-card.is-medium .order-operational-load-metrics > div {
    min-width: 0 !important;
  }

  .order-operational-load-card.is-medium .order-operational-load-metric-suggestion {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    width: fit-content !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    min-height: 0 !important;
    padding: 4px 10px !important;
    justify-self: start !important;
    align-self: start !important;
    border-radius: 999px !important;
    background: #dff6e8 !important;
    color: #287a52 !important;
    font-size: 0.68rem !important;
    font-weight: 500 !important;
    line-height: 1.1 !important;
    white-space: nowrap !important;
  }
}

/* Critical state: compact recommendation and single disclaimer. */
.order-operational-load-card.is-critical .order-operational-load-context {
  padding: 18px 20px 16px;
  border-color: #f4c8d2;
  border-radius: 14px;
  background: #fff1f4;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading {
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading [data-load-preview-use-date] {
  flex: 0 0 auto;
  align-self: flex-start;
  min-height: 34px;
  margin-left: auto;
  padding: 7px 12px;
  border-color: #159b61;
  background: #159b61;
  color: #fff;
  white-space: nowrap;
}

.order-operational-load-context-heading [data-load-preview-use-date][hidden] {
  display: none !important;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading > span {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
  border-radius: 50%;
  border: 0;
  background: #ffd8e1;
  color: #fff;
  box-shadow: none;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading > span i {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 50%;
  background: #ef4764;
  color: #fff;
  font-size: 0.9rem;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading > div {
  gap: 5px;
  padding-top: 2px;
}

.order-operational-load-card.is-critical .order-operational-load-context-heading strong {
  color: #c92e55;
  font-size: 0.95rem;
}

.order-operational-load-card.is-critical .order-operational-load-status-pill {
  width: fit-content;
  padding: 5px 10px;
  background: #ffd9e2;
  color: #dc3154;
  font-size: 0.72rem;
}

.order-operational-load-card.is-critical .order-operational-load-context > p[data-load-preview-summary] {
  margin: 0 0 13px;
  color: #5c698d;
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.45;
}

.order-operational-load-card.is-critical .order-operational-load-details {
  margin-top: 0;
  padding-top: 12px;
  border-top-color: #f4c8d2;
}

.order-operational-load-card.is-critical .order-operational-load-details > strong {
  margin-bottom: 10px;
  color: #173c87;
  font-size: 0.78rem;
}

.order-operational-load-card.is-critical .order-operational-load-metrics {
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.7fr) minmax(0, 1.5fr);
}

.order-operational-load-card.is-critical .order-operational-load-metrics > div {
  min-height: 52px;
  padding: 0 10px;
  border-left-color: #f4c8d2;
}

.order-operational-load-card.is-critical .order-operational-load-metrics > div:first-child {
  padding-left: 0;
}

.order-operational-load-card.is-critical .order-operational-load-metrics small {
  margin-bottom: 4px;
  color: #6e7897;
  font-size: 0.64rem;
}

.order-operational-load-card.is-critical .order-operational-load-metrics b {
  color: #173c87;
  font-size: 0.76rem;
}

.order-operational-load-card.is-critical .order-operational-load-metric-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  padding: 5px 7px;
  border-radius: 999px;
  background: #dff6e8;
  color: #168451 !important;
  font-size: 0.6rem;
  font-weight: 700;
  white-space: nowrap;
}

.order-operational-load-card.is-critical .order-operational-load-preview-suggestion {
  display: block;
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: transparent;
}

.order-operational-load-card.is-critical .order-operational-load-preview-suggestion > i,
.order-operational-load-card.is-critical .order-operational-load-preview-suggestion-copy {
  display: none;
}

.order-operational-load-card.is-critical .order-operational-load-preview-suggestion .btn {
  width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid #159b61;
  border-radius: 9px;
  background: #159b61;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
}

.order-operational-load-card.is-critical .order-operational-load-preview-actions {
  margin-top: 7px;
  text-align: center;
}

.order-operational-load-card.is-critical .order-operational-load-preview-actions p {
  justify-content: center;
  color: #727b96;
  font-size: 0.6rem;
  line-height: 1.3;
}

@media (max-width: 767px) {
  .order-operational-load-card.is-critical .order-operational-load-context {
    padding: 16px 14px 14px;
  }

  .order-operational-load-card.is-critical .order-operational-load-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 0;
  }

  .order-operational-load-card.is-critical .order-operational-load-metrics > div:nth-child(3) {
    grid-column: 1 / -1;
    padding-left: 0;
    border-left: 0;
  }
}

/* /ingreso mobile - el CTA critico queda en flujo, despues del detalle. */
@media (max-width: 767px) {
  .order-operational-load-card.is-critical .order-operational-load-context {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading {
    display: contents !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > span {
    grid-column: 1 !important;
    grid-row: 1 !important;
    align-self: start !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > div {
    grid-column: 1 !important;
    grid-row: 1 !important;
    min-width: 0 !important;
    margin-left: 58px !important;
    align-self: start !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context > p[data-load-preview-summary] {
    grid-column: 1 !important;
    grid-row: 2 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context > p[data-load-preview-detail] {
    grid-column: 1 !important;
    grid-row: 3 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-details {
    grid-column: 1 !important;
    grid-row: 4 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-preview-suggestion {
    grid-column: 1 !important;
    grid-row: 5 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > [data-load-preview-use-date] {
    grid-column: 1 !important;
    grid-row: 6 !important;
    width: 100% !important;
    min-width: 0 !important;
    margin: 10px 0 0 !important;
    justify-self: stretch !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-preview-actions {
    grid-column: 1 !important;
    grid-row: 7 !important;
  }
}

/* /ingreso iPad - el CTA critico queda debajo del contenido, en flujo. */
@media (min-width: 768px) and (max-width: 1199px) {
  .order-operational-load-card.is-critical .order-operational-load-context {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading {
    display: contents !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > span {
    grid-column: 1 !important;
    grid-row: 1 !important;
    align-self: start !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > div {
    grid-column: 1 !important;
    grid-row: 1 !important;
    min-width: 0 !important;
    margin-left: 58px !important;
    align-self: start !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context > p[data-load-preview-summary] {
    grid-column: 1 !important;
    grid-row: 2 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context > p[data-load-preview-detail] {
    grid-column: 1 !important;
    grid-row: 3 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-details {
    grid-column: 1 !important;
    grid-row: 4 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-preview-suggestion {
    grid-column: 1 !important;
    grid-row: 5 !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-context-heading > [data-load-preview-use-date] {
    grid-column: 1 !important;
    grid-row: 6 !important;
    width: 100% !important;
    min-width: 0 !important;
    margin: 10px 0 0 !important;
    justify-self: stretch !important;
  }

  .order-operational-load-card.is-critical .order-operational-load-preview-actions {
    grid-column: 1 !important;
    grid-row: 7 !important;
  }
}

@media (max-width: 767px) {
    .third-mobile-section-switcher {
        margin: 8px 0 10px !important;
        padding: 4px !important;
        gap: 4px !important;
    }

    .third-mobile-switch-btn {
        min-height: 40px !important;
    }

    .third-party-form-card,
    .third-party-list-card {
        margin-top: 0 !important;
    }
}

@media (max-width: 767px) {
    /*
      /third-parties mobile:
      el espacio grande entre metricas, switch y panel viene del gap del padre.
    */
    .third-party-page.page-shell {
        gap: 10px !important;
    }

    .third-mobile-section-switcher {
        margin: 0 !important;
        padding: 4px !important;
        gap: 4px !important;
    }

    .third-mobile-switch-btn {
        min-height: 40px !important;
    }

    [data-third-mobile-panel="register"],
    [data-third-mobile-panel="records"] {
        margin-top: 0 !important;
    }
}

@media (max-width: 767px) {
    /*
      /third-parties mobile:
      reducir espacio vacio inferior al final del scroll.
    */
    .third-party-page.page-shell {
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell > :last-child {
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell [data-third-mobile-panel="register"],
    .third-party-page.page-shell [data-third-mobile-panel="records"] {
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
    }

    .third-party-page.page-shell .third-party-form-card,
    .third-party-page.page-shell .third-party-list-card {
        margin-bottom: 0 !important;
    }

    body:has(.third-party-page) .dashboard-main,
    body:has(.third-party-page) .main-content {
        padding-bottom: calc(78px + env(safe-area-inset-bottom, 0px)) !important;
    }
}

@media (max-width: 767px) {
    /*
      /third-parties mobile:
      recuperar padding interno del card del formulario.
    */
    .third-party-page.page-shell .third-party-form-card {
        padding-bottom: 18px !important;
    }

    .third-party-page.page-shell .third-party-form-card form,
    .third-party-page.page-shell .third-party-form-card .form-grid {
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell .third-party-form-card .form-actions,
    .third-party-page.page-shell .third-party-form-card button[type="submit"] {
        margin-bottom: 0 !important;
    }

    /*
      Mantener aire visual entre el ultimo elemento y el bottom nav,
      pero sin dejar bloque blanco gigante.
    */
    .third-party-page.page-shell {
        padding-bottom: 10px !important;
        margin-bottom: 0 !important;
        gap: 10px !important;
    }

    .third-party-page.page-shell > :last-child {
        margin-bottom: 0 !important;
    }

    /*
      Reducir el padding inferior del scroll SOLO en third-parties.
      Antes quedo demasiado alto.
    */
    body:has(.third-party-page) .dashboard-main,
    body:has(.third-party-page) .main-content {
        padding-bottom: calc(58px + env(safe-area-inset-bottom, 0px)) !important;
    }
}

@media (max-width: 767px) {
    /*
      /third-parties mobile:
      evitar doble espacio inferior entre page, content y main.
    */
    body:has(.third-party-page) .dashboard-main,
    body:has(.third-party-page) .main-content {
        padding-bottom: 8px !important;
    }

    body:has(.third-party-page) .content-area,
    body:has(.third-party-page) .page-content {
        padding-bottom: calc(82px + env(safe-area-inset-bottom, 0px)) !important;
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell {
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
        gap: 10px !important;
        min-height: auto !important;
        height: auto !important;
    }

    .third-party-page.page-shell > :last-child {
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell [data-third-mobile-panel="register"],
    .third-party-page.page-shell [data-third-mobile-panel="records"] {
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
    }

    .third-party-page.page-shell .third-party-form-card,
    .third-party-page.page-shell .third-party-list-card {
        padding-bottom: 18px !important;
        margin-bottom: 0 !important;
    }
}

.third-records-filters-toggle,
.third-records-scroll-top-btn {
    display: none;
}

@media (max-width: 767px) {
    /*
      /third-parties mobile - filtros avanzados y volver arriba en Registros.
    */
    .third-records-filters-toggle {
        width: 100% !important;
        min-height: 44px !important;
        margin: 14px 0 12px !important;
        padding: 0 14px !important;

        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;

        border-radius: 14px !important;
        border: 1px solid rgba(188, 201, 236, 0.82) !important;
        background: rgba(255, 255, 255, 0.94) !important;
        color: var(--primary) !important;
        font-weight: 700 !important;
        box-shadow: none !important;
    }

    .third-records-filters-toggle span {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
    }

    .third-records-filters-toggle.is-open > i:last-child {
        transform: rotate(180deg) !important;
    }

    .third-records-advanced-filters {
        display: grid !important;
        gap: 14px !important;
        width: 100% !important;

        margin: 0 0 14px !important;
        padding: 14px 12px !important;

        border-radius: 16px !important;
        border: 1px solid rgba(180, 207, 221, 0.62) !important;
        background: rgba(248, 251, 255, 0.72) !important;
    }

    .third-records-advanced-filters[hidden] {
        display: none !important;
    }

    .third-records-advanced-filters .form-field,
    .third-records-advanced-filters .form-group,
    .third-records-advanced-filters label,
    .third-records-advanced-filters input,
    .third-records-advanced-filters select,
    .third-records-advanced-filters button {
        width: 100% !important;
        max-width: none !important;
    }

    .third-records-advanced-filters input,
    .third-records-advanced-filters select {
        min-height: 44px !important;
        border-radius: 14px !important;
    }

    .third-records-advanced-filters .btn,
    .third-records-advanced-filters button[type="submit"],
    .third-records-advanced-filters button[type="reset"] {
        min-height: 46px !important;
        border-radius: 14px !important;
        justify-content: center !important;
        font-weight: 700 !important;
    }

    .third-records-scroll-top-btn {
        position: fixed !important;
        right: 18px !important;
        bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
        z-index: 60 !important;

        width: 38px !important;
        height: 38px !important;
        min-width: 38px !important;
        min-height: 38px !important;

        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;

        border-radius: 999px !important;
        border: 1px solid rgba(188, 201, 236, 0.86) !important;
        background: rgba(255, 255, 255, 0.96) !important;
        color: var(--primary) !important;
        box-shadow: 0 10px 24px rgba(47, 36, 64, 0.16) !important;

        opacity: 0 !important;
        visibility: hidden !important;
        transform: translateY(8px) scale(0.96) !important;
        pointer-events: none !important;
        transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease !important;
    }

    body.third-mobile-tab-records .third-records-scroll-top-btn.is-visible {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) scale(1) !important;
        pointer-events: auto !important;
    }
}

.third-records-filters-toggle,
.third-records-scroll-top-btn {
    display: none;
}

@media (max-width: 767px) {
    /*
      /third-parties mobile - filtros avanzados y volver arriba en Registros.
    */
    .third-records-filters-toggle {
        width: 100% !important;
        min-height: 44px !important;
        margin: 14px 0 12px !important;
        padding: 0 14px !important;

        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;

        border-radius: 14px !important;
        border: 1px solid rgba(188, 201, 236, 0.82) !important;
        background: rgba(255, 255, 255, 0.94) !important;
        color: var(--primary) !important;
        font-weight: 700 !important;
        box-shadow: none !important;
    }

    .third-records-filters-toggle span {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
    }

    .third-records-filters-toggle.is-open > i:last-child {
        transform: rotate(180deg) !important;
    }

    .third-records-advanced-filters {
        display: grid !important;
        gap: 14px !important;
        width: 100% !important;

        margin: 0 0 14px !important;
        padding: 14px 12px !important;

        border-radius: 16px !important;
        border: 1px solid rgba(180, 207, 221, 0.62) !important;
        background: rgba(248, 251, 255, 0.72) !important;
    }

    .third-records-advanced-filters[hidden] {
        display: none !important;
    }

    .third-records-advanced-filters .form-field,
    .third-records-advanced-filters .form-group,
    .third-records-advanced-filters label,
    .third-records-advanced-filters input,
    .third-records-advanced-filters select,
    .third-records-advanced-filters button {
        width: 100% !important;
        max-width: none !important;
    }

    .third-records-advanced-filters input,
    .third-records-advanced-filters select {
        min-height: 44px !important;
        border-radius: 14px !important;
    }

    .third-records-advanced-filters .btn,
    .third-records-advanced-filters button[type="submit"],
    .third-records-advanced-filters button[type="reset"] {
        min-height: 46px !important;
        border-radius: 14px !important;
        justify-content: center !important;
        font-weight: 700 !important;
    }

    .third-records-scroll-top-btn {
        position: fixed !important;
        right: 18px !important;
        bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
        z-index: 60 !important;

        width: 38px !important;
        height: 38px !important;
        min-width: 38px !important;
        min-height: 38px !important;

        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;

        border-radius: 999px !important;
        border: 1px solid rgba(188, 201, 236, 0.86) !important;
        background: rgba(255, 255, 255, 0.96) !important;
        color: var(--primary) !important;
        box-shadow: 0 10px 24px rgba(47, 36, 64, 0.16) !important;

        opacity: 0 !important;
        visibility: hidden !important;
        transform: translateY(8px) scale(0.96) !important;
        pointer-events: none !important;
        transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease !important;
    }

    body.third-mobile-tab-records .third-records-scroll-top-btn.is-visible {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) scale(1) !important;
        pointer-events: auto !important;
    }
}

.third-records-filters-toggle,
.third-records-scroll-top-btn {
    display: none;
}

@media (max-width: 767px) {
    .third-records-filters-toggle {
        width: 100% !important;
        min-height: 44px !important;
        margin: 14px 0 12px !important;
        padding: 0 14px !important;

        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;

        border-radius: 14px !important;
        border: 1px solid rgba(188, 201, 236, 0.82) !important;
        background: rgba(255, 255, 255, 0.94) !important;
        color: var(--primary) !important;
        font-weight: 700 !important;
        box-shadow: none !important;
    }

    .third-records-filters-toggle span {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
    }

    .third-records-filters-toggle.is-open > i:last-child {
        transform: rotate(180deg) !important;
    }

    .third-records-advanced-filters {
        display: grid !important;
        gap: 14px !important;
        width: 100% !important;

        margin: 0 0 14px !important;
        padding: 14px 12px !important;

        border-radius: 16px !important;
        border: 1px solid rgba(180, 207, 221, 0.62) !important;
        background: rgba(248, 251, 255, 0.72) !important;
    }

    .third-records-advanced-filters[hidden] {
        display: none !important;
    }

    .third-records-advanced-filters .form-field,
    .third-records-advanced-filters .form-group,
    .third-records-advanced-filters label,
    .third-records-advanced-filters input,
    .third-records-advanced-filters select,
    .third-records-advanced-filters button {
        width: 100% !important;
        max-width: none !important;
    }

    .third-records-advanced-filters input,
    .third-records-advanced-filters select {
        min-height: 44px !important;
        border-radius: 14px !important;
    }

    .third-records-advanced-filters .btn,
    .third-records-advanced-filters button[type="submit"],
    .third-records-advanced-filters button[type="reset"] {
        min-height: 46px !important;
        border-radius: 14px !important;
        justify-content: center !important;
        font-weight: 700 !important;
    }

    .third-records-scroll-top-btn {
        position: fixed !important;
        right: 18px !important;
        bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
        z-index: 60 !important;

        width: 38px !important;
        height: 38px !important;
        min-width: 38px !important;
        min-height: 38px !important;

        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;

        border-radius: 999px !important;
        border: 1px solid rgba(188, 201, 236, 0.86) !important;
        background: rgba(255, 255, 255, 0.96) !important;
        color: var(--primary) !important;
        box-shadow: 0 10px 24px rgba(47, 36, 64, 0.16) !important;

        opacity: 0 !important;
        visibility: hidden !important;
        transform: translateY(8px) scale(0.96) !important;
        pointer-events: none !important;
        transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease !important;
    }

    body.third-mobile-tab-records .third-records-scroll-top-btn.is-visible {
        opacity: 1 !important;
        visibility: visible !important;
        transform: translateY(0) scale(1) !important;
        pointer-events: auto !important;
    }
}

@media (min-width: 900px) and (max-width: 1199px) {
    :root {
        --responsive-shell-padding: 1rem;
        --responsive-main-padding: 1rem;
        --responsive-section-gap: 18px;
        --responsive-component-gap: 12px;
    }
}

@media (min-width: 576px) and (max-width: 899px) {
    :root {
        --responsive-shell-padding: 0.875rem;
        --responsive-main-padding: 0.875rem;
        --responsive-section-gap: 16px;
        --responsive-component-gap: 12px;
    }
}

@media (max-width: 575px) {
    :root {
        --responsive-shell-padding: 0.75rem;
        --responsive-main-padding: 0.75rem;
        --responsive-section-gap: 14px;
        --responsive-component-gap: 10px;
    }
}

@media (max-width: 768px) {
    input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]),
    select,
    textarea,
    .form-control,
    .form-select,
    .search-input,
    .clients-table-search-input,
    .summary-orders-modal-search-input,
    .modal input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]),
    .modal select,
    .modal textarea,
    .mobile-service-search input,
    .service-picker-form-grid input,
    .service-picker-form-grid select,
    .service-picker-form-grid textarea,
    .client-dni-input-shell input,
    .order-amounts-row .form-group input,
    .service-price-input-wrap input,
    #service-quantity-input,
    #service-price-input,
    #service-size-select,
    .service-line-add-row input,
    .service-line-add-row select,
    .rug-add-row input,
    .rug-add-row select,
    .carpet-add-row input,
    .carpet-add-row select,
    .duvet-add-row input,
    .duvet-add-row select,
    #allOrdersModal .all-orders-filter-form input,
    #allOrdersModal .all-orders-filter-form select,
    #allOrdersModal .orders-total-filters input,
    #allOrdersModal .orders-total-filters select,
    #otherPendingOrdersModal input,
    #otherPendingOrdersModal select,
    .orders-filters-bar input,
    .orders-filters-bar select,
    .orders-filters-center input,
    .orders-filters-center select,
    .filter-group-inline input,
    .filter-group-inline select,
    .cash-box-form-grid--compact input,
    .cash-box-form-grid--compact select,
    .admin-sequence-form input[type="number"],
    .admin-cash-box-form input[type="number"],
    .admin-whatsapp-textarea-group textarea,
    .legacy-order-form input,
    .legacy-order-form select,
    .legacy-order-form textarea {
        font-size: 16px !important;
        line-height: 1.3 !important;
    }
}

.payments-summary-section .summary-payment-action-cell {
    width: 56px;
    text-align: right;
}

.summary-payment-open-btn,
.mobile-payment-open-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    border: 0;
    border-radius: 14px;
    background: #F4F3FF;
    color: #4A5BA8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.summary-payment-open-btn:hover,
.mobile-payment-open-btn:hover {
    background: #ECE9FF;
}

.summary-payments-method-modal .summary-orders-modal-search,
.summary-payments-method-modal .summary-empty-state {
    margin-top: 0;
}

@media (max-width: 767px) {
    .mobile-payment-summary-card {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto auto;
        align-items: center;
    }

    .mobile-payment-total {
        justify-self: end;
    }

    .mobile-payment-open-btn {
        justify-self: end;
    }
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    height: 100%;
    min-height: 100%;
    overflow: hidden;
}

body {
    font-family: var(--font-family-base);
    background: var(--app-background);
    color: var(--text);
    padding-left: var(--safe-area-left);
    padding-right: var(--safe-area-right);
}

body.modal-open {
    overflow: hidden;
}

a {
    color: var(--primary);
    text-decoration: none;
}

.dashboard-frame {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    padding: 1.5rem;
    overflow: hidden;
}

.dashboard-shell,
.app-layout {
    display: flex;
    width: 100%;
    height: calc(100vh - 3rem);
    height: calc(100dvh - 3rem);
    background: rgba(255, 255, 255, 0.52);
    border: 1px solid rgba(85, 156, 173, 0.15);
    border-radius: 32px;
    box-shadow: 0 28px 60px rgba(74, 88, 153, 0.12);
    overflow: hidden;
}

.sidebar {
    width: 220px;
    flex: 0 0 220px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 1.5rem 12px;
    background: var(--panel-surface);
    backdrop-filter: blur(10px);
    border-right: 1px solid rgba(85, 156, 173, 0.2);
    position: sticky;
    top: 0;
    height: 100%;
    overflow: hidden;
}

.sidebar-top {
    display: grid;
    gap: 0.75rem;
    flex-shrink: 0;
}

.sidebar-logo {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 88px;
    height: 88px;
    padding: 12px 16px;
    background: transparent;
    border: none;
    box-shadow: none;
    overflow: hidden;
    contain: layout paint;
}

.sidebar-logo-img {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    max-width: 180px;
    height: 64px;
    max-height: 64px;
    object-fit: contain;
    object-position: center;
    background: transparent;
    opacity: 1;
    visibility: visible;
    transition: none !important;
    animation: none !important;
    backface-visibility: hidden;
}

.login-logo {
    display: block;
    width: 100%;
    max-width: 260px;
    height: auto;
    max-height: 120px;
    object-fit: contain;
    object-position: center;
    transition: none !important;
    animation: none !important;
}

.sidebar-divider {
    height: 1px;
    width: 100%;
    background: rgba(0, 0, 0, 0.08);
    margin-bottom: 12px;
}

.sidebar-copy {
    margin: 0;
    padding: 0 0.35rem;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.5;
}

.sidebar-nav {
    display: grid;
    gap: 0.45rem;
    margin-top: 1.5rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 4px;
    align-content: start;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    min-height: 46px;
    padding: 0.8rem 0.95rem;
    border-radius: 14px;
    color: var(--text);
    font-weight: 600;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.sidebar-link i {
    font-size: 16px;
    opacity: 0.7;
    min-width: 20px;
    text-align: center;
}

.sidebar-link-dot {
    width: 10px;
    height: 10px;
    flex: 0 0 10px;
    border-radius: 999px;
    background: rgba(85, 156, 173, 0.45);
}

.sidebar-link:hover {
    background: var(--color-sidebar-link-hover-bg);
    color: var(--primary);
    transform: translateX(2px);
}

.sidebar-link.active {
    background: var(--color-sidebar-active-bg);
    color: var(--color-sidebar-active-text);
    box-shadow: var(--shadow-soft);
}

.sidebar-link.active .sidebar-link-dot {
    background: rgba(255, 255, 255, 0.92);
}

.sidebar-link.active i {
    opacity: 1;
    color: inherit;
}

.sidebar-footer {
    margin-top: auto;
    flex-shrink: 0;
}

.sidebar-user-card {
    display: grid;
    gap: 0.9rem;
    width: 100%;
    margin: 12px 0 0;
    padding: 0.9rem;
    border-radius: 16px;
    background: var(--color-sidebar-card-bg);
    border: 1px solid var(--color-sidebar-card-border);
    box-shadow: var(--shadow-soft);
    box-sizing: border-box;
    transition: border-color 0.18s ease;
}

.sidebar-user-card:hover {
    border-color: rgba(0, 0, 0, 0.12);
}

.sidebar-user-main {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.sidebar-avatar {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(145deg, var(--primary), var(--secondary));
    color: var(--white);
    font-size: 1rem;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(74, 88, 153, 0.16);
}

.sidebar-avatar-button {
    border: none;
    cursor: pointer;
    padding: 0;
}

.sidebar-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.sidebar-user-copy {
    min-width: 0;
    display: grid;
    gap: 0.22rem;
}

.sidebar-user-name {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--primary);
}

.sidebar-user-name .first-name {
    font-size: 14px;
    font-weight: 600;
    color: inherit;
}

.sidebar-user-name .last-name {
    font-size: 14px;
    color: inherit;
    font-weight: 600;
    opacity: 1;
    word-break: break-word;
}

.sidebar-user-role {
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.sidebar-logout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0.65rem 0.85rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--color-border);
    color: var(--secondary);
    font-weight: 700;
    font-size: 0.9rem;
    transition: background 0.18s ease, transform 0.18s ease;
}

.sidebar-logout:hover {
    background: var(--color-button-outline-hover-bg);
    transform: translateY(-1px);
}

.dashboard-main,
.main-content {
    flex: 1;
    min-width: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    padding: 1.5rem;
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.26) 0%, rgba(248, 239, 246, 0.66) 100%);
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 24px;
    background: var(--color-topbar-bg);
    border: 1px solid var(--color-topbar-border);
    box-shadow: var(--shadow);
    background-size: auto;
    background-position: center;
    background-repeat: no-repeat;
}

.topbar.has-brand-header-background {
    background-color: var(--color-topbar-bg);
    background-image: var(--brand-header-bg-image);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

.mobile-page-header.has-brand-header-background {
    background-image: var(--brand-header-bg-image);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

.topbar-copy {
    min-width: 0;
}

.topbar-greeting {
    margin: 0 0 0.35rem;
    color: var(--secondary);
    font-weight: 700;
}

.topbar-title {
    margin: 0;
    color: var(--primary);
    font-size: clamp(1.65rem, 2.4vw, 2.3rem);
}

.topbar-subtitle {
    margin: 0.4rem 0 0;
    color: var(--muted);
    max-width: 54ch;
    line-height: 1.5;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.header-actions {
    position: relative;
}

.header-top-row {
    display: contents;
}

.header-main-button {
    display: contents;
}

.mobile-header-menu-btn,
.mobile-fab-new-order {
    display: none;
}

.mobile-orders-list {
    display: none;
}

.notifications-shell {
    position: relative;
}

.notification-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid var(--color-border);
    background: rgba(255, 255, 255, 0.92);
    color: var(--primary);
    font-size: 1rem;
    font-weight: 700;
    box-shadow: var(--shadow-soft);
    cursor: pointer;
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.notification-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(47, 36, 64, 0.12);
}

.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--color-notification-badge-bg);
    color: var(--color-notification-badge-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    box-shadow: var(--shadow-soft);
}

.notifications-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: min(360px, calc(100vw - 32px));
    max-width: calc(100vw - 32px);
    padding: 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(74, 88, 153, 0.12);
    box-shadow: 0 24px 48px rgba(47, 36, 64, 0.16);
    display: none;
    z-index: 1200;
}

.notifications-shell.is-open .notifications-dropdown {
    display: block;
}

.notifications-dropdown-header h3 {
    margin: 0;
    font-size: 1rem;
    color: var(--primary);
}

.notifications-list {
    display: grid;
    gap: 10px;
    margin-top: 12px;
}

.notification-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(248, 239, 246, 0.5);
    color: inherit;
    text-decoration: none;
    transition: background 0.2s ease;
}

.notification-item:hover {
    background: rgba(243, 221, 233, 0.7);
}

.notification-item--critical {
    background: rgba(220, 38, 38, 0.08);
}

.notification-item--critical:hover {
    background: rgba(220, 38, 38, 0.12);
}

.notification-item--critical .notification-item-count {
    background: rgba(220, 38, 38, 0.14);
    color: #991b1b;
}

.notification-item--warning {
    background: rgba(245, 158, 11, 0.1);
}

.notification-item--warning:hover {
    background: rgba(245, 158, 11, 0.15);
}

.notification-item--warning .notification-item-count {
    background: rgba(245, 158, 11, 0.16);
    color: #92400e;
}

.notification-item--positive {
    background: rgba(22, 163, 74, 0.08);
}

.notification-item--positive:hover {
    background: rgba(22, 163, 74, 0.12);
}

.notification-item--positive .notification-item-count {
    background: rgba(22, 163, 74, 0.14);
    color: #166534;
}

.notification-item--neutral .notification-item-count {
    background: rgba(74, 88, 153, 0.12);
    color: var(--primary);
}

.notification-item-icon {
    font-size: 1rem;
}

.notification-item-copy {
    min-width: 0;
    color: var(--primary);
    font-size: 0.94rem;
    line-height: 1.35;
}

.notification-item-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 28px;
    padding: 0 8px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.12);
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
}

.notifications-divider {
    height: 1px;
    background: rgba(74, 88, 153, 0.12);
    margin: 12px 0;
}

.notifications-empty {
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.45;
}

.notification-item-status {
    margin-top: 0;
}

.mobile-bottom-nav,
.mobile-more-overlay,
.mobile-more-sheet {
    display: none;
}

.mobile-bottom-nav {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 999;
    grid-template-columns: repeat(6, 1fr);
    gap: 4px;
    padding: 8px;
    border-radius: 22px;
    background: var(--color-mobile-nav-bg);
    backdrop-filter: blur(14px);
    border: 1px solid var(--color-mobile-sheet-border);
    box-shadow: var(--shadow-card);
}

.mobile-nav-item {
    border: 0;
    background: transparent;
    text-decoration: none;
    color: var(--color-mobile-nav-text);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 54px;
    border-radius: 16px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
}

.mobile-nav-item i {
    font-size: 18px;
}

.mobile-nav-item.active,
.mobile-nav-item:hover {
    background: var(--color-mobile-nav-active-bg);
    color: var(--color-mobile-nav-active-text);
}

.mobile-more-overlay {
    position: fixed;
    inset: 0;
    background: rgba(47, 36, 64, 0.3);
    z-index: 1100;
}

.mobile-more-sheet {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 84px;
    z-index: 1101;
    padding: 16px;
    border-radius: 24px;
    background: var(--color-mobile-sheet-bg);
    border: 1px solid var(--color-mobile-sheet-border);
    box-shadow: 0 18px 40px rgba(47, 36, 64, 0.18);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 12px;
}

.mobile-more-sheet.is-open,
.mobile-more-overlay.is-open {
    display: block;
}

.mobile-more-sheet-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-border);
}

.mobile-more-sheet-heading {
    min-width: 0;
    flex: 1;
}

.mobile-more-sheet-header h3 {
    margin: 0;
    color: var(--primary);
    font-size: 20px;
    line-height: 1.15;
    font-weight: 700;
}

.mobile-more-sheet-heading p {
    margin: 4px 0 0;
    font-size: 12px;
    line-height: 1.35;
    color: #7B7188;
}

.mobile-more-close-btn {
    width: 42px;
    height: 42px;
    min-width: 42px;
    min-height: 42px;
    border: 0;
    border-radius: 999px;
    background: #F4F5FB;
    color: #1F2A5A;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.mobile-more-sheet-links {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 16px;
    padding-bottom: 4px;
}

.mobile-more-section {
    display: grid;
    gap: 8px;
}

.mobile-more-section-title {
    font-size: 11px;
    line-height: 1.1;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    padding: 0 2px;
}

.mobile-more-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 56px;
    padding: 12px 14px;
    border-radius: 18px;
    background: var(--color-surface-soft);
    border: 1px solid var(--color-border-strong);
    color: var(--primary);
    font-weight: 700;
    text-decoration: none;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.mobile-more-link:hover,
.mobile-more-link:active {
    background: var(--color-surface);
    border-color: var(--color-button-outline-border);
    transform: translateY(-1px);
}

.mobile-more-link-icon {
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.mobile-more-link-copy {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.mobile-more-link-copy strong {
    font-size: 14px;
    line-height: 1.15;
    font-weight: 700;
    color: var(--color-title);
}

.mobile-more-link-copy small {
    font-size: 12px;
    line-height: 1.25;
    color: var(--color-text-secondary);
}

.mobile-more-link-danger {
    color: #b42318;
}

.mobile-more-link-danger .mobile-more-link-icon {
    background: #FFF0F0;
    color: #C92A2A;
}

.mobile-more-link-danger .mobile-more-link-copy strong {
    color: #B42318;
}

.mobile-more-link-danger .mobile-more-link-copy small {
    color: #9A6A6A;
}

.header-datetime {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    min-width: 0;
    color: var(--primary);
}

.header-datetime .time {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.1;
}

.header-datetime .date {
    font-size: 0.81rem;
    line-height: 1.2;
    color: var(--muted);
    opacity: 0.7;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    width: 100%;
}

.admin-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    width: 100%;
    align-items: stretch;
}

.admin-management-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    align-items: stretch;
}

.admin-appearance-card {
    grid-column: auto;
}

.admin-cashbox-card {
    grid-column: 1/-1;
}

.admin-management-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 24px;
    gap: 10px;
}


.admin-management-card__content {
    display: grid;
    gap: 6px;
    margin-bottom: 0;
    flex-grow: 1;
}

.admin-management-card__content .section-subtitle {
    margin-bottom: 0;
    line-height: 1.4;
}

.admin-management-card__actions {
    margin-top: auto;
}

.admin-users-actions {
    align-items: center;
    justify-content: flex-start;
    gap: 16px;
}

.admin-clients-actions,
.admin-sequence-actions {
    justify-content: flex-start;
}

.admin-sequence-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-grow: 1;
    min-width: 0;
    max-width: 100%;
}

.admin-sequence-stack {
    display: grid;
    gap: 8px;
}

.admin-sequence-panel,
.admin-cash-box-form {
    padding: 10px 12px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.72);
    border: 1px solid rgba(180, 207, 221, 0.38);
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    max-width: 100%;
}

.admin-sequence-grid,
.admin-cash-box-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px 12px;
    min-width: 0;
    max-width: 100%;
}

.admin-sequence-grid .form-group,
.admin-cash-box-grid .form-group {
    margin-bottom: 0;
    gap: 6px;
    min-width: 0;
    max-width: 100%;
}

.admin-sequence-actions,
.admin-cash-box-form .form-actions {
    justify-content: flex-start;
    padding-top: 12px;
    margin-top: 4px;
}

.admin-sequence-grid label,
.admin-cash-box-grid label {
    margin-bottom: 0;
}

.admin-sequence-form input[type="number"],
.admin-cash-box-form input[type="number"] {
    width: 100%;
    max-width: 100%;
    min-height: 44px;
    box-sizing: border-box;
}

.admin-cash-box-stack {
    display: grid;
    gap: 12px;
}

.admin-cash-box-base-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.admin-cash-box-base-form,
.admin-cash-box-initialization-form {
    display: grid;
    gap: 8px;
    min-width: 0;
}

.admin-cash-box-control-setup,
.admin-cash-box-control-status,
.admin-cash-box-control-disabled {
    margin-top: 4px;
    padding-top: 12px;
    border-top: 1px solid rgba(180, 207, 221, 0.42);
}

.admin-cash-box-control-setup {
    display: grid;
    gap: 7px;
}

.admin-cash-box-control-setup-heading,
.admin-cash-box-control-status {
    display: flex;
    align-items: center;
    gap: 7px;
}

.admin-cash-box-control-setup-heading h4 {
    margin: 0;
    color: var(--primary);
    font-size: 0.88rem;
    font-weight: 700;
}

.admin-cash-box-control-status {
    justify-content: flex-start;
    color: #166534;
}

.admin-cash-box-control-status-copy {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #166534;
    font-size: 0.8rem;
    font-weight: 700;
}

.admin-cash-box-control-disabled {
    margin-bottom: 0;
}

@media (min-width: 768px) and (orientation: landscape), (min-width: 1025px) {
    .admin-sequence-stack {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
        gap: 12px;
    }

    .admin-cash-box-base-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }
}

.admin-whatsapp-card {
    padding: 24px;
}

.admin-whatsapp-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.admin-whatsapp-new-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 46px;
}

.admin-whatsapp-editor {
    display: grid;
    gap: 18px;
}

.admin-whatsapp-template-list {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.admin-whatsapp-template-pill {
    border: 1px solid rgba(85, 156, 173, 0.2);
    background: #fff;
    color: var(--primary);
    border-radius: 999px;
    padding: 10px 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.admin-whatsapp-template-pill:hover,
.admin-whatsapp-template-pill.is-active {
    background: rgba(85, 156, 173, 0.08);
    border-color: rgba(85, 156, 173, 0.38);
    box-shadow: 0 8px 18px rgba(85, 156, 173, 0.1);
}

.admin-whatsapp-form {
    display: grid;
    gap: 14px;
}

.admin-whatsapp-create-form {
    display: grid;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.82);
    border: 1px solid rgba(180, 207, 221, 0.38);
}

.admin-whatsapp-create-textarea textarea {
    min-height: 104px;
    resize: vertical;
}

.admin-whatsapp-create-actions {
    justify-content: flex-end;
}

.admin-whatsapp-shell {
    display: grid;
    grid-template-columns: minmax(280px, 0.92fr) minmax(0, 2fr);
    gap: 16px;
    align-items: stretch;
}

.admin-whatsapp-variables,
.admin-whatsapp-textarea-group {
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.72);
    border: 1px solid rgba(180, 207, 221, 0.38);
}

.admin-whatsapp-variables {
    display: grid;
    gap: 8px;
    align-content: flex-start;
    height: 100%;
}

.admin-whatsapp-variables-label {
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 700;
}

.admin-whatsapp-variables-copy {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.admin-whatsapp-variable-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.admin-whatsapp-variable-chip {
    border: 1px solid rgba(85, 156, 173, 0.16);
    background: rgba(255, 255, 255, 0.95);
    color: var(--primary);
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.admin-whatsapp-variable-chip:hover {
    background: rgba(85, 156, 173, 0.08);
    border-color: rgba(85, 156, 173, 0.34);
    transform: translateY(-1px);
}

.admin-whatsapp-textarea-group {
    margin-bottom: 0;
    gap: 10px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.admin-whatsapp-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-whatsapp-delete-btn {
    min-height: 42px;
    padding: 10px 14px;
    border-radius: 14px;
    border: 1px solid rgba(211, 72, 109, 0.18);
    background: rgba(255, 255, 255, 0.92);
    color: #c1406f;
    box-shadow: none;
}

.admin-whatsapp-delete-btn:hover,
.admin-whatsapp-delete-btn:focus-visible {
    background: rgba(255, 240, 244, 0.96);
    border-color: rgba(211, 72, 109, 0.3);
    color: #b33662;
}

.admin-whatsapp-delete-btn.is-hidden {
    display: none;
}

.admin-whatsapp-textarea-group textarea {
    min-height: 144px;
    resize: vertical;
    flex: 1 1 auto;
}

.admin-whatsapp-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-whatsapp-counter {
    color: var(--primary);
    font-size: 0.92rem;
}

.admin-whatsapp-actions {
    justify-content: flex-end;
}

.admin-whatsapp-create-modal {
    width: min(920px, calc(100vw - 32px));
}

.admin-whatsapp-create-modal-body {
    padding-top: 0;
}

.admin-whatsapp-create-form-modal {
    margin-top: 0;
}

.admin-whatsapp-create-modal-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.9fr);
    gap: 16px;
    align-items: stretch;
}

.admin-whatsapp-create-modal-main {
    display: grid;
    gap: 12px;
}

.admin-whatsapp-variables-modal {
    height: 100%;
}

@media (max-width: 1180px) {
    .admin-management-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .admin-management-grid {
        grid-template-columns: 1fr;
    }

    .admin-appearance-card,
    .admin-sequences-card,
    .admin-cashbox-card {
        grid-column: 1 / -1;
    }

    .admin-whatsapp-header {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-whatsapp-new-btn {
        width: 100%;
    }

    .admin-whatsapp-shell {
        grid-template-columns: 1fr;
    }

    .admin-whatsapp-create-modal-grid {
        grid-template-columns: 1fr;
    }

    .admin-users-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

.dashboard-overview-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    align-items: stretch;
}

.metric-card {
    min-height: 148px;
    display: grid;
    align-content: space-between;
}

.chart-shell {
    position: relative;
    width: 100%;
    min-height: 320px;
}

.chart-empty-state {
    display: grid;
    place-items: center;
    min-height: 220px;
    padding: 16px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.88);
    border: 1px dashed rgba(190, 220, 230, 0.95);
    color: #6F6A7F;
    text-align: center;
    font-weight: 700;
    line-height: 1.35;
}

.chart-empty-state[hidden] {
    display: none !important;
}

.chart-external-tooltip {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1500;
    min-width: 176px;
    max-width: 280px;
    padding: 10px 14px;
    border-radius: 14px;
    background: rgba(47, 36, 64, 0.94);
    color: #fff;
    box-shadow: 0 10px 24px rgba(31, 42, 90, 0.24);
    pointer-events: none;
    opacity: 0;
    transform: translate3d(0, 0, 0);
    transition: opacity 0.12s ease;
}

.chart-external-tooltip.is-visible {
    opacity: 1;
}

.chart-external-tooltip-title {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 700;
}

.chart-external-tooltip-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 12px;
    line-height: 1.2;
    min-width: 0;
}

.chart-external-tooltip-row + .chart-external-tooltip-row {
    margin-top: 4px;
}

.chart-external-tooltip-separator {
    height: 1px;
    margin: 8px 0 6px;
    background: rgba(255, 255, 255, 0.18);
}

.chart-external-tooltip-row--footer strong {
    color: #dbe8ff;
}

.chart-external-tooltip-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.chart-external-tooltip-dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    flex: 0 0 8px;
}

.chart-external-tooltip-row strong {
    flex: 0 0 auto;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.01em;
}

.donut-chart-shell {
    min-height: 290px;
}

.order-status-chart-wrapper {
    flex: 1;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 8px 18px;
    overflow: hidden;
}

.order-status-chart-wrapper canvas {
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
    max-height: 272px !important;
    pointer-events: auto;
}

.admin-metrics-stack {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.general-summary-grid,
.kpi-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    margin-top: 16px;
    gap: 16px;
    width: 100%;
    box-sizing: border-box;
    align-items: stretch;
}

.kpi-card-grid--four {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.general-summary-card {
    min-width: 0;
    width: 100%;
    overflow: hidden;
}

.dashboard-overview-grid > .content-card,
.dashboard-summary-card,
.dashboard-third-party-card,
.dashboard-status-card {
    height: 100%;
    min-height: unset;
}

.dashboard-audit-card,
.dashboard-third-party-card {
    display: flex;
    flex-direction: column;
}

.dashboard-status-card {
    display: flex;
    flex-direction: column;
}

@media (max-width: 1100px) {
    .dashboard-overview-grid {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .dashboard-overview-grid > .content-card,
    .dashboard-summary-card,
    .dashboard-third-party-card,
    .dashboard-status-card {
        height: auto;
    }

}

.general-summary-item,
.kpi-card {
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(190, 220, 230, 0.9);
    box-shadow: 0 6px 18px rgba(38, 55, 90, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 88px;
    overflow: hidden;
    position: relative;
}

.general-summary-item .info-chip-label,
.general-summary-item strong {
    word-break: normal;
    overflow-wrap: break-word;
}

.general-summary-item .info-chip-label {
    flex: 1 1 auto;
    line-height: 1.25;
    white-space: normal;
    max-width: 100%;
    hyphens: none;
    color: #736278;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
}

.general-summary-item strong {
    flex: 0 0 auto;
    color: var(--color-title);
    font-size: clamp(22px, 2vw, 30px);
    line-height: 1.1;
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.third-party-dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px;
    align-items: stretch;
}

.third-party-action-area {
    display: flex;
    align-items: center;
    justify-content: stretch;
    margin-top: auto;
}

.kpi-card-action-area {
    grid-column: 1 / -1;
}

.third-party-action-area .btn {
    width: 100%;
}

.kpi-card::before,
.general-summary-item::before,
.kpi-card::after,
.general-summary-item::after {
    content: none !important;
    display: none !important;
}

.metric-label {
    color: var(--muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.metric-value {
    margin: 0;
    font-size: clamp(2rem, 4vw, 2.7rem);
    color: var(--primary);
}

@media (min-width: 1025px) {
    .dashboard-summary-card .kpi-card-grid,
    .dashboard-summary-card .kpi-card-grid--four,
    .dashboard-audit-card .kpi-card-grid,
    .dashboard-audit-card .kpi-card-grid--four,
    .dashboard-third-party-card .kpi-card-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }

    .dashboard-summary-card .general-summary-item,
    .dashboard-audit-card .general-summary-item,
    .dashboard-third-party-card .general-summary-item {
        min-width: 240px;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .general-summary-grid,
    .kpi-card-grid,
    .kpi-card-grid--four,
    .third-party-dashboard-grid,
    .dashboard-audit-grid,
    .summary-operational-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .general-summary-item,
    .kpi-card,
    .summary-operational-kpi {
        min-height: 104px;
    }

    .dashboard-audit-header {
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .delayed-orders-card {
        display: flex;
        flex-direction: column;
        padding: 20px;
        border-radius: 24px;
        overflow: visible;
    }

    .delayed-orders-content {
        height: auto;
        width: 100%;
        flex-direction: row;
        align-items: flex-start;
        justify-content: space-between;
        gap: 18px;
    }

    .delayed-orders-actions {
        width: auto;
        justify-content: flex-end;
        align-items: flex-start;
        flex-wrap: nowrap;
    }

    .delayed-orders-info h3 {
        margin: 8px 0 10px;
        font-size: clamp(20px, 2.8vw, 22px);
        line-height: 1.2;
    }

    .delayed-orders-info p {
        font-size: 14px;
        line-height: 1.35;
    }

    .alert-label {
        font-size: 12px;
        letter-spacing: 0.06em;
    }

    .delayed-orders-count-stack {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 4px;
        text-align: right;
    }

    .delayed-orders-count {
        font-size: clamp(36px, 5vw, 40px);
    }

    .delayed-orders-count-label {
        font-size: 13px;
        line-height: 1.2;
        color: #736278;
    }

    .delayed-orders-action-desktop {
        display: none !important;
    }

    .delayed-orders-action-mobile-wrap {
        display: block;
        width: 100%;
        margin-top: 16px;
    }

    .delayed-orders-action-mobile {
        display: inline-flex;
        width: 100%;
        justify-content: center;
        min-height: 46px;
        border-radius: 18px;
        font-size: 15px;
        font-weight: 700;
    }
}

@media (max-width: 767px) {
    .general-summary-grid,
    .kpi-card-grid,
    .kpi-card-grid--four,
    .dashboard-audit-grid,
    .summary-operational-kpis {
        grid-template-columns: 1fr;
    }

    .third-party-dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .general-summary-item,
    .kpi-card,
    .summary-operational-kpi {
        padding: 14px 16px;
        min-height: 96px;
        gap: 12px;
    }

    .general-summary-item strong,
    .summary-operational-kpi strong {
        font-size: clamp(20px, 6vw, 28px);
    }

    .dashboard-audit-header {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .delayed-orders-content {
        height: auto;
        width: 100%;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
    }

    .delayed-orders-actions {
        width: auto;
        justify-content: flex-end;
        align-items: center;
        flex-wrap: nowrap;
    }

    .delayed-orders-count-stack {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 4px;
        text-align: right;
    }

    .delayed-orders-count-label {
        margin-top: 0;
        color: #736278;
    }

    .delayed-orders-action-desktop {
        display: none !important;
    }

    .delayed-orders-action-mobile-wrap {
        display: block;
        width: 100%;
        margin-top: 14px;
    }

    .delayed-orders-action-mobile {
        display: inline-flex;
        width: 100%;
        justify-content: center;
        min-height: 44px;
        border-radius: 16px;
        font-size: 14px;
    }

    .audit-action-desktop {
        display: none !important;
    }

    .audit-action-mobile-wrap {
        display: block !important;
    }

    .audit-action-mobile {
        display: flex;
    }

    .dashboard-header-action-btn,
    a.dashboard-header-action-btn,
    button.dashboard-header-action-btn {
        justify-self: end;
        min-width: 0;
    }
}

@media (max-width: 520px) {
    .third-party-dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 430px) {
    .delayed-orders-content {
        gap: 12px;
    }

    .delayed-orders-count {
        font-size: 34px;
    }

    .delayed-orders-count-label {
        font-size: 12px;
        line-height: 1.2;
    }

    .delayed-orders-info h3 {
        font-size: 19px;
        line-height: 1.2;
    }

    .delayed-orders-info p {
        font-size: 13px;
        line-height: 1.35;
    }

    .delayed-orders-card {
        padding: 16px;
    }

    .delayed-orders-action-mobile-wrap {
        margin-top: 14px;
    }

    .delayed-orders-action-mobile {
        min-height: 44px;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .dashboard-audit-header {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .audit-action-desktop {
        display: none !important;
    }

    .audit-action-mobile-wrap {
        display: block !important;
    }

    .audit-action-mobile {
        display: flex;
    }
}

.section-header {
    /* margin-bottom: var(--component-gap, 0rem); */
}

.dashboard-audit-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 16px;
}

.dashboard-audit-header-copy {
    min-width: 0;
}

.audit-action-desktop {
    display: inline-flex;
}

.audit-action-mobile-wrap {
    display: none !important;
    margin-top: 16px;
}

.audit-action-mobile {
    display: none;
    width: 100%;
}

@media (min-width: 1025px) {
    .audit-action-desktop {
        display: inline-flex !important;
    }

    .audit-action-mobile-wrap,
    .audit-action-mobile {
        display: none !important;
    }
}

.tablet-app-mode .dashboard-audit-header {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
}

.tablet-app-mode .audit-action-desktop {
    display: none !important;
}

.tablet-app-mode .audit-action-mobile-wrap {
    display: block !important;
}

.tablet-app-mode .audit-action-mobile {
    display: flex !important;
    width: 100% !important;
}

.dashboard-header-action-btn,
a.dashboard-header-action-btn,
button.dashboard-header-action-btn {
    width: auto !important;
    min-width: 164px;
    min-height: 46px;
    padding: 0 20px;
    justify-self: end;
    justify-content: center !important;
    white-space: nowrap;
}

.section-title {
    margin: 0 0 0.25rem;
    color: var(--color-title);
    font-weight: var(--heading-font-weight, 700);
    font-size: calc(1em * var(--heading-font-size-adjust, 1));
}

.section-subtitle {
    margin: 0;
    line-height: 1.35;
    color: var(--color-text-secondary);
}

.dashboard-subtitle-plain {
    font-style: normal !important;
    font-family: inherit !important;
}

.business-indicators-card *,
.business-indicators-card .card-description,
.business-indicators-card .section-subtitle,
.business-indicators-card small {
    font-style: normal !important;
}

.dashboard-indicators-card {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 420px;
}

.dashboard-indicators-header {
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.dashboard-indicators-card .section-subtitle,
.dashboard-status-card .section-subtitle {
    font-style: normal !important;
    font-family: inherit !important;
}

.dashboard-indicators-card .chart-shell {
    flex: 1;
    min-height: 320px;
}

.dashboard-indicators-card .chart-shell canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
}

.reports-chart-card,
.reports-chart-shell {
    width: 100%;
    min-width: 0;
}

.reports-chart-card {
    overflow: hidden;
}

.reports-chart-shell {
    position: relative;
    height: 280px;
    min-height: 280px;
    max-height: 280px;
    overflow: hidden;
}

.reports-chart-shell canvas {
    display: block;
    width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    pointer-events: auto !important;
}

.reports-chart-shell .chart-empty-state {
    pointer-events: none;
}

.card-title {
    margin: 0 0 0.25rem;
    color: var(--primary);
}

.card-subtitle {
    margin: 0;
    line-height: 1.35;
    color: var(--muted);
}

.section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.section-head-align-start {
    align-items: flex-start;
}

.section-tools {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}

.table-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.warning-card {
    border-color: rgba(221, 194, 127, 0.6);
    background: linear-gradient(180deg, rgba(255, 248, 232, 0.95) 0%, rgba(255, 252, 244, 0.98) 100%);
}

.delayed-orders-card {
    width: 100%;
    min-width: 0;
    min-height: 150px;
    padding: 24px;
    overflow: hidden;
}

.delayed-orders-content {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.delayed-orders-info {
    min-width: 0;
    flex: 1;
}

.delayed-orders-info h3 {
    margin: 4px 0 6px;
    overflow-wrap: anywhere;
    word-break: break-word;
    color: var(--primary);
}

.delayed-orders-info p {
    margin: 0;
    opacity: 0.75;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.alert-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--secondary);
    letter-spacing: 0.04em;
}

.client-dni-field-head {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
}

.client-dni-input-shell {
    position: relative;
}

.client-dni-input-shell input {
    padding-right: 44px;
}

.client-dni-input-shell.is-editing input {
    border-color: rgba(74, 91, 168, 0.42);
    box-shadow: 0 0 0 3px rgba(74, 91, 168, 0.08);
}

.client-dni-inline-trigger {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #5a67a5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
}

.client-dni-inline-trigger:hover,
.client-dni-inline-trigger:focus-visible {
    background: rgba(74, 91, 168, 0.08);
    color: #304a9a;
    outline: none;
}

.client-dni-edit-state {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 22px;
    padding: 1px 8px;
    border-radius: 999px;
    background: rgba(74, 91, 168, 0.08);
    color: #304a9a;
    font-size: 0.72rem;
    font-weight: 700;
}

.client-dni-warning {
    margin-top: 8px;
    color: #8a5207;
    font-size: 0.82rem;
    line-height: 1.3;
}

.client-dni-warning.is-hidden,
.client-dni-edit-state.is-hidden {
    display: none !important;
}

.delayed-orders-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.delayed-orders-count-stack {
    display: inline-flex;
    align-items: flex-end;
    gap: 8px;
}

.delayed-orders-count {
    font-size: 32px;
    font-weight: 700;
    line-height: 1;
    color: var(--color-title);
}

.delayed-orders-count-label {
    font-size: 13px;
    opacity: 0.7;
}

.delayed-orders-action-mobile-wrap,
.delayed-orders-action-mobile {
    display: none;
}

@media (max-width: 1024px) {
    .delayed-orders-action-desktop {
        display: none !important;
    }

    .delayed-orders-action-mobile-wrap {
        display: block !important;
        width: 100% !important;
        margin-top: 18px !important;
    }

    .delayed-orders-action-mobile {
        display: inline-flex !important;
        width: 100% !important;
        justify-content: center !important;
    }
}

@media (min-width: 1025px) {
    .delayed-orders-action-desktop {
        display: inline-flex !important;
    }

    .delayed-orders-action-mobile-wrap,
    .delayed-orders-action-mobile {
        display: none !important;
    }
}

.table-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    flex-wrap: wrap;
}

.table-card-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.general-summary-card-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: auto;
    padding-top: 16px;
}

.general-summary-card-actions .dashboard-card-primary-action {
    width: min(100%, 280px);
}

.dashboard-card-primary-action,
.dashboard-card-primary-action.btn-secondary,
a.dashboard-card-primary-action.btn-secondary,
button.dashboard-card-primary-action.btn-secondary {
    width: 100%;
    min-height: 46px;
    background: var(--primary) !important;
    border: 1px solid var(--primary) !important;
    color: #fff !important;
    box-shadow: var(--shadow-button-primary-strong) !important;
}

.dashboard-card-primary-action:hover,
.dashboard-card-primary-action:focus-visible,
.dashboard-card-primary-action.btn-secondary:hover,
.dashboard-card-primary-action.btn-secondary:focus-visible,
a.dashboard-card-primary-action.btn-secondary:hover,
a.dashboard-card-primary-action.btn-secondary:focus-visible,
button.dashboard-card-primary-action.btn-secondary:hover,
button.dashboard-card-primary-action.btn-secondary:focus-visible {
    background: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
    color: #fff !important;
    box-shadow: var(--shadow-button-primary-hover) !important;
}

.dashboard-card-primary-action:active,
.dashboard-card-primary-action.btn-secondary:active,
a.dashboard-card-primary-action.btn-secondary:active,
button.dashboard-card-primary-action.btn-secondary:active {
    background: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
    color: #fff !important;
    box-shadow: var(--shadow-button-primary-active) !important;
}

.content-area,
.page-content {
    display: grid;
    flex: 1;
    min-height: 0;
    width: 100%;
    gap: 1.5rem;
    grid-template-columns: 1fr;
    align-items: start;
    align-content: start;
    overflow: auto;
    padding-right: 0.2rem;
}

@media (min-width: 1025px) {
    body:not(.tablet-app-mode) .dashboard-main,
    body:not(.tablet-app-mode) .main-content {
        padding: clamp(12px, 1.2vw, 12px);
    }

    body:not(.tablet-app-mode) .dashboard-main::before,
    body:not(.tablet-app-mode) .main-content::before {
        content: none !important;
        display: none !important;
    }

    body:not(.tablet-app-mode) .topbar {
  position: sticky;
    top: 12px;
    z-index: 1200;

    margin: 0 0 34px;
    padding: 20px 24px;

    width: 100%;
    max-width: 100%;
    box-sizing: border-box;

    border-radius: 30px;
    background: var(--color-topbar-bg);
    border: 1px solid var(--color-topbar-border);

    box-shadow:
        0px -110px 10px 60px var(--color-sticky-topbar-mask),
        0px 10px 24px rgba(38, 55, 90, 0.06),
        0px 1px 4px rgba(38, 55, 90, 0.035);

    backdrop-filter: none;
    overflow: visible;
    isolation: auto;
}

    body:not(.tablet-app-mode) .topbar.has-brand-header-background {
    background-color: var(--color-topbar-bg);
    background-image: var(--brand-header-bg-image);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

    body:not(.tablet-app-mode) .topbar::before {
    content: none !important;
    display: none !important;
}

    body:not(.tablet-app-mode) .topbar > * {
        position: relative;
        z-index: 2;
    }

    body:not(.tablet-app-mode) .flash-messages,
    body:not(.tablet-app-mode) .toast-container,
    body:not(.tablet-app-mode) .alerts-container,
    body:not(.tablet-app-mode) .toast-message,
    body:not(.tablet-app-mode) .flash-message {
        z-index: 2000;
    }

    body:not(.tablet-app-mode) .topbar-copy {
        display: grid;
        gap: 6px;
    }

    body:not(.tablet-app-mode) .topbar-title,
    body:not(.tablet-app-mode) .page-title {
        font-size: clamp(2.1rem, 2.8vw, 3rem);
        line-height: 1.02;
    }

    body:not(.tablet-app-mode) .topbar-subtitle,
    body:not(.tablet-app-mode) .page-subtitle,
    body:not(.tablet-app-mode) .topbar-copy p {
        max-width: 56ch;
        font-size: 0.98rem;
        line-height: 1.45;
    }

    body:not(.tablet-app-mode) .topbar-actions,
    body:not(.tablet-app-mode) .header-actions {
        gap: 14px;
    }

    body:not(.tablet-app-mode) .notification-button {
        width: 44px;
        height: 44px;
        box-shadow: 0 8px 18px rgba(47, 36, 64, 0.08);
    }

    body:not(.tablet-app-mode) .header-main-button .btn,
    body:not(.tablet-app-mode) .header-main-button > a.btn,
    body:not(.tablet-app-mode) .header-main-button > button.btn {
        min-height: 48px;
        padding-inline: 22px;
        border-radius: 16px;
    }

    body:not(.tablet-app-mode) .dashboard-indicators-card {
        min-height: 0;
    }

    body:not(.tablet-app-mode) .dashboard-indicators-card .chart-shell {
        flex: 0 0 auto;
        height: clamp(300px, 34vh, 340px);
        min-height: 300px;
        max-height: 340px;
    }

    body:not(.tablet-app-mode) .dashboard-indicators-card .chart-shell canvas {
        width: 100% !important;
        height: 100% !important;
        max-height: 100% !important;
        pointer-events: auto !important;
    }

    body:not(.tablet-app-mode) .dashboard-main,
    body:not(.tablet-app-mode) .main-content,
    body:not(.tablet-app-mode) .sidebar-nav {
        scrollbar-width: thin;
        scrollbar-color: rgba(74, 88, 153, 0.32) transparent;
        scrollbar-gutter: stable;
    }

    body:not(.tablet-app-mode) .dashboard-main,
    body:not(.tablet-app-mode) .main-content {
        overflow-x: hidden;
        overflow-y: auto;
    }

    body:not(.tablet-app-mode) .sidebar-nav {
        padding-right: 8px;
    }

    body:not(.tablet-app-mode) .dashboard-main,
    body:not(.tablet-app-mode) .main-content,
    body:not(.tablet-app-mode) .sidebar-nav {
        scrollbar-gutter: stable both-edges;
    }

    body:not(.tablet-app-mode) .content-area,
    body:not(.tablet-app-mode) .page-content {
        overflow: visible;
        padding-right: 0;
    }

    body:not(.tablet-app-mode) .dashboard-main::-webkit-scrollbar,
    body:not(.tablet-app-mode) .main-content::-webkit-scrollbar,
    body:not(.tablet-app-mode) .sidebar-nav::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }

    body:not(.tablet-app-mode) .dashboard-main::-webkit-scrollbar-track,
    body:not(.tablet-app-mode) .main-content::-webkit-scrollbar-track,
    body:not(.tablet-app-mode) .sidebar-nav::-webkit-scrollbar-track {
        background: transparent;
        border-radius: 999px;
    }

    body:not(.tablet-app-mode) .dashboard-main::-webkit-scrollbar-thumb,
    body:not(.tablet-app-mode) .main-content::-webkit-scrollbar-thumb {
        background: rgba(74, 88, 153, 0.28);
        border-radius: 999px;
        border: 2px solid transparent;
        background-clip: padding-box;
    }

    body:not(.tablet-app-mode) .sidebar-nav::-webkit-scrollbar-thumb {
        background: rgba(74, 88, 153, 0.18);
        border-radius: 999px;
        border: 2px solid transparent;
        background-clip: padding-box;
    }

    body:not(.tablet-app-mode) .dashboard-main::-webkit-scrollbar-thumb:hover,
    body:not(.tablet-app-mode) .main-content::-webkit-scrollbar-thumb:hover {
        background: rgba(74, 88, 153, 0.46);
        background-clip: padding-box;
    }

    body:not(.tablet-app-mode) .sidebar-nav:hover::-webkit-scrollbar-thumb {
        background: rgba(74, 88, 153, 0.32);
        background-clip: padding-box;
    }
}

.card {
    width: 100%;
    min-width: 0;
    background: var(--panel-surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: var(--card-padding, 22px);
    box-shadow: var(--shadow);
}

.card-full,
.table-card,
.wide-card {
    grid-column: 1 / -1;
}

.page-section,
.page-grid {
    display: grid;
    width: 100%;
    gap: var(--section-gap, 1.5rem);
    align-items: start;
    min-height: 0;
}

.page-shell,
.report-page-shell,
.dashboard-page-shell,
.third-party-page,
.summary-page {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.page-shell > *,
.report-page-shell > *,
.dashboard-page-shell > *,
.third-party-page > *,
.summary-page > * {
    min-width: 0;
}

.dashboard-page-shell {
    display: grid;
    width: 100%;
    gap: var(--section-gap, 1.5rem);
    align-items: start;
}

.page-shell .card,
.page-shell .content-card,
.page-shell .table-card,
.page-shell .wide-card,
.page-shell .full-width,
.page-shell .content-card.full-width,
.page-shell .responsive-grid,
.page-shell .admin-grid,
.page-shell .admin-actions-grid,
.page-shell .general-summary-grid,
.page-shell .reports-kpi-grid,
.page-shell .summary-grid,
.page-shell .summary-two-columns,
.page-shell .third-party-metrics-grid {
    min-width: 0;
    box-sizing: border-box;
}

.responsive-grid {
    width: 100%;
    display: grid;
    gap: var(--section-gap, 1.5rem);
    align-items: stretch;
}

.cards-grid,
.dashboard-grid,
.admin-grid,
.admin-actions-grid,
.summary-grid,
.summary-two-columns,
.reports-kpi-grid {
    gap: var(--section-gap, 24px);
}

.responsive-grid.two-cols:not(.admin-sequence-grid):not(.admin-cash-box-grid),
.two-columns {
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
}

.responsive-grid.three-cols {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.full-width,
.content-card.full-width {
    width: 100%;
    grid-column: 1 / -1;
}

.compact-card {
    max-width: none;
}

.content-card {
    width: 100%;
    height: 100%;
    min-width: 0;
    padding: var(--card-padding, 24px);
    border-radius: 24px;
    box-sizing: border-box;
    background: var(--panel-surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.content-card.stretch {
    min-height: 100%;
}

.cards-grid,
.dashboard-grid,
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    width: 100%;
}

.summary-page {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.summary-two-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(320px, 1fr));
    gap: 24px;
    width: 100%;
    align-items: stretch;
}

.summary-card {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.total-day-card {
    width: 100%;
}

.total-day-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.total-day-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.quick-links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    width: 100%;
    margin-top: 10px;
}

.reports-tabs {
    display: grid;
    gap: 1.5rem;
}

.reports-tab-bar {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    overflow-x: auto;
    overflow-y: hidden;
    margin-top: 16px;
}

.reports-tab-button {
    border: 1px solid var(--color-segmented-border, rgba(85, 156, 173, 0.22));
    background: var(--color-segmented-bg, rgba(255, 255, 255, 0.82));
    color: var(--color-segmented-text, var(--primary));
    border-radius: 999px;
    padding: 0.75rem 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
    white-space: nowrap;
}

.reports-tab-button:not(.active):hover {
    border-color: var(--color-segmented-border, rgba(74, 88, 153, 0.28));
    background: var(--color-segmented-hover-bg, rgba(74, 88, 153, 0.08));
    color: var(--color-segmented-text, var(--primary));
}

.reports-tab-button.active,
.reports-tab-button.active:hover,
.reports-tab-button.active:focus-visible {
    background: var(--color-segmented-active-bg, var(--primary));
    color: var(--color-segmented-active-text, var(--white));
    border-color: var(--color-segmented-active-bg, var(--primary));
    box-shadow: none;
/* outline: 2px solid var(--color-segmented-border, rgba(85, 156, 173, 0.22)); */
    outline-offset: 2px;
}

.reports-tab-panel {
    display: none;
    gap: 1.5rem;
}

.reports-tab-panel.is-active {
    display: grid;
}

.reports-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    width: 100%;
}

.report-page-shell,
.report-main-shell {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.report-page-shell {
    grid-column: 1 / -1;
    gap: 0;
}

.report-main-shell {
    width: 100%;
}

.report-main-shell .reports-tabs,
.report-main-shell .reports-tab-panel,
.report-main-shell .reports-kpi-grid,
.report-main-shell .admin-grid {
    min-width: 0;
}

.report-main-shell .reports-kpi-grid > .card.content-card {
    min-width: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-content: flex-end;
    align-items: flex-start;
}

.reports-kpi-grid--clients {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

@media (min-width: 1025px) {
    .report-main-shell {
        padding: 1.5rem;
    }

    .report-main-shell .section-header {
        min-width: 0;
    }

    .report-main-shell .reports-tab-panel {
        gap: 1.25rem;
    }

    .report-main-shell .reports-kpi-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
        gap: 16px;
        align-items: stretch;
    }

    .report-main-shell .reports-kpi-grid > .card.content-card,
    .report-main-shell .reports-kpi-grid > .kpi-card {
        min-width: 240px;
        min-height: 0;
    }

    .report-main-shell .kpi-money,
    .report-main-shell .kpi-number,
    .report-main-shell .kpi-percent,
    .report-main-shell .metric-value {
        min-width: 0;
        max-width: 100%;
    }
}

.report-export-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    width: 100%;
}

.report-export-button {
    border: 1px solid var(--line);
    text-align: left;
    cursor: pointer;
    font: inherit;
}

table th,
table td,
.history-table th,
.history-table td,
.reports-table th,
.reports-table td,
.orders-table th,
.orders-table td,
.expenses-table th,
.expenses-table td,
.admin-table th,
.admin-table td,
.clients-table th,
.clients-table td {
    text-align: center;
    vertical-align: middle;
}

.clients-table-card .table-card-header {
    display: block;
}

.clients-table-card-header-copy {
    width: 100%;
}

.clients-table-search {
    margin-top: 14px;
    width: 100%;
    max-width: none;
    margin-bottom: 12px;
}

.clients-table-search-input {
    width: 100%;
}

.clients-table-empty-row td {
    padding: 24px 16px;
    color: var(--text-muted);
    font-weight: 600;
}

.report-export-button .quick-link-icon,
.report-export-button .quick-link-title,
.report-export-button .quick-link-text {
    pointer-events: none;
}

.report-alert-card {
    min-width: 0;
}

.operation-stat-header,
.operation-stat-title-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    width: 100%;
    flex-direction: column;
}

.operation-stat-header h3,
.operation-stat-header .info-chip-label,
.operation-stat-title {
    margin: 0;
    min-width: 0;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: inherit;
    opacity: 0.75;
}

.operation-stat-header strong,
.operation-stat-description {
    margin-top: 8px;
    margin-bottom: 0;
}

.report-alert-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.card-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.card-header-row .btn {
    align-self: center;
    flex-shrink: 0;
}

.filter-inline-row {
    display: flex;
    align-items: end;
    gap: 0.1rem;
    flex-wrap: wrap;
}

.filter-inline-row .form-group {
    flex: 1 1 260px;
}

.icon-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    border-radius: 10px;
    border: none;
    background: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
    text-decoration: none;
    padding: 0;
}

.icon-btn i {
    font-size: 14px;
}

.icon-btn:hover {
    transform: translateY(-1px);
}

.service-view-btn {
    border-color: rgba(85, 156, 173, 0.24);
    background: rgba(221, 244, 248, 0.68);
    color: var(--primary);
}

.order-row-actions {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.edit-btn {
    color: #4A5899;
}

.edit-btn:hover {
    background: var(--color-button-outline-hover-bg);
}

.delete-btn {
    color: #DC2626;
}

.delete-btn:hover {
    background: rgba(220, 38, 38, 0.12);
}

.filter-btn {
    color: #559CAD;
}

.filter-btn:hover {
    background: rgba(85, 156, 173, 0.14);
}

.actions-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.actions-cell form,
.order-admin-tools form {
    margin: 0;
}

.actions-cell .inline-form {
    margin-left: 0;
}

.status-chip,
.amount-pill,
.pill-chip {
    margin-left: 16px;
    /* margin-right: auto; */
}

.filter-inline-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.summary-total-highlight {
    min-width: 0;
    padding: 0.95rem 1rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(85, 156, 173, 0.2);
    display: grid;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.summary-total-highlight strong {
    color: var(--primary);
    font-size: clamp(1.45rem, 2.5vw, 2rem);
}

.summary-expenses-card {
    height: 100%;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.summary-expenses-list {
    flex: 1;
    min-height: 0;
    max-height: none;
    overflow-y: auto;
    overflow-x: auto;
    margin-bottom: 16px;
}

.summary-expenses-total {
    margin-top: auto;
    margin-bottom: 0;
}

.summary-total-box {
    margin-top: auto;
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
}

.summary-total-box span {
    font-weight: 600;
    opacity: 0.75;
}

.summary-total-box strong {
    white-space: nowrap;
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
}

.summary-page-redesigned {
    gap: 22px;
}

.summary-header-card {
    overflow: hidden;
}

.summary-header-head {
    align-items: center;
}

.summary-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.btn-outline-primary {
    background: #ffffff;
    color: var(--primary);
    border: 1px solid rgba(74, 88, 153, 0.28);
    box-shadow: none;
}

.btn-outline-primary:hover {
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary-dark);
}

.summary-back-link {
    display: inline-flex;
    align-items: center;
    margin-bottom: 0.85rem;
    color: var(--secondary);
    font-weight: 700;
    text-decoration: none;
    font-size: 0;
}

.summary-back-link:hover {
    text-decoration: underline;
}

.summary-back-link::before {
    content: "\2190\00a0Regresar a resumen";
    font-size: 0.95rem;
}

.summary-back-link--inline {
    margin-bottom: 0;
    white-space: nowrap;
}

.summary-page > .summary-back-link {
    display: none;
}

.summary-icon-action {
    width: 36px;
    min-width: 36px;
    min-height: 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.summary-table-link {
    color: var(--secondary);
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.summary-table-link:hover {
    text-decoration: underline;
}

.summary-back-button,
.summary-table-button {
    white-space: nowrap;
}

.summary-table-button {
    background: var(--primary);
    color: #ffffff;
    border: 1px solid var(--primary);
    box-shadow: none;
}

.summary-table-button:hover,
.summary-table-button:focus-visible {
    background: var(--primary-dark);
    color: #ffffff;
    border-color: var(--primary-dark);
}

.summary-header-filters {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.summary-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
}

.summary-kpi-card {
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 138px;
}

.summary-kpi-icon {
    width: 56px;
    height: 56px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 56px;
    font-size: 1.2rem;
}

.summary-kpi-card.entered .summary-kpi-icon {
    background: rgba(22, 163, 74, 0.12);
    color: #15803d;
}

.summary-kpi-card.delivered .summary-kpi-icon {
    background: rgba(37, 99, 235, 0.12);
    color: #1d4ed8;
}

.summary-kpi-card.process .summary-kpi-icon {
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
}

.summary-kpi-card.pending .summary-kpi-icon {
    background: rgba(218, 68, 160, 0.12);
    color: #c0267c;
}

.summary-kpi-copy {
    display: grid;
    gap: 6px;
}

.summary-kpi-label {
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.summary-kpi-value {
    color: var(--primary);
    font-size: clamp(1.9rem, 3vw, 2.5rem);
    font-weight: 700;
    line-height: 1;
}

.summary-kpi-note {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.35;
}

.summary-ledger-grid {
    grid-template-columns: 1fr;
}

.summary-ledger-grid--two-columns {
    grid-template-columns: repeat(2, minmax(320px, 1fr));
}

.summary-finance-grid {
    align-items: stretch;
}

.summary-block {
    border: 1px solid rgba(85, 156, 173, 0.18);
}

.summary-block-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.summary-block-title-group {
    display: grid;
    gap: 4px;
}

.summary-link {
    color: var(--secondary);
    font-weight: 700;
    white-space: nowrap;
}

.summary-link-button {
    background: transparent;
    border: 0;
    padding: 0;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
}

.summary-orders-modal .modal-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.summary-orders-modal-search {
    width: 100%;
}

.summary-orders-modal-search-input {
    width: 100%;
}

.summary-orders-modal-table-shell {
    max-height: 56vh;
}

.summary-orders-modal-table th,
.summary-orders-modal-table td {
    text-align: center;
    vertical-align: middle;
}

.summary-method-note {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.35;
}

.summary-expense-note {
    margin: 10px 0 0;
}

.summary-info-tooltip {
    border: 0;
    background: transparent;
    padding: 0;
    margin-left: 6px;
    vertical-align: middle;
}

.summary-info-tooltip i {
    font-size: 0.82rem;
}

.summary-info-tooltip--title {
    margin-left: 8px;
}

.summary-method-note,
.summary-expense-note,
.cash-box-metric small,
.cash-box-movements-header span,
.cash-box-balance-note {
    display: none !important;
}

.summary-orders-block--entered .section-title {
    color: #15803d;
}

.summary-orders-block--delivered .section-title {
    color: #1d4ed8;
}

.summary-ledger-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.summary-ledger-table-wrapper {
    min-height: 0;
}

.summary-ledger-table tbody tr {
    transition: background 0.18s ease;
}

.summary-ledger-table tbody tr:hover {
    background: rgba(74, 88, 153, 0.06);
}

.summary-code-pill,
.summary-method-pill {
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
}

.summary-method-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.summary-method-badge.method-cash {
    background: rgba(22, 163, 74, 0.12);
    color: #166534;
}

.summary-method-badge.method-yape {
    background: rgba(139, 92, 246, 0.14);
    color: #6d28d9;
}

.summary-method-badge.method-plin {
    background: rgba(20, 184, 166, 0.14);
    color: #0f766e;
}

.summary-method-badge.method-card {
    background: rgba(31, 41, 55, 0.12);
    color: #111827;
}

.summary-method-badge.method-transferencia {
    background: rgba(37, 99, 235, 0.12);
    color: #1d4ed8;
}

.summary-method-badge.method-otro,
.summary-method-badge.method-unspecified {
    background: rgba(74, 88, 153, 0.10);
    color: #4a5899;
}

@media (max-width: 1199px) {
    .summary-page .summary-expenses-day-card .summary-expense-row {
        grid-template-columns: 36px minmax(0, 1fr) max-content !important;
    }

    .summary-page .summary-expenses-day-card .mobile-expense-left {
        grid-column: 1 / 3 !important;
        min-width: 0 !important;
        display: grid !important;
        grid-template-columns: 36px minmax(0, 1fr) !important;
        gap: 12px !important;
        align-items: center !important;
    }

    .summary-page .summary-expenses-day-card .summary-expense-row-payment {
        grid-column: 3 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: 8px !important;
        min-width: 0 !important;
        white-space: nowrap !important;
    }

    .summary-page .summary-expenses-day-card .summary-expense-row-payment .summary-expense-row-amount {
        grid-column: auto !important;
        justify-self: auto !important;
        align-self: center !important;
    }
}

.summary-rest-amount {
    font-weight: 700;
    white-space: nowrap;
}

.summary-rest-amount.is-pending {
    color: #b42318;
}

.summary-rest-amount.is-settled {
    color: #15803d;
}

.summary-empty-state {
    min-height: 140px;
    border-radius: 18px;
    border: 1px dashed rgba(85, 156, 173, 0.26);
    background: rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    color: var(--muted);
}

.summary-balance-card .total-day-content {
    align-items: center;
}

.summary-total-box--income {
    background: rgba(22, 163, 74, 0.08);
    border-color: rgba(22, 163, 74, 0.16);
}

.summary-total-box--income strong {
    color: #166534;
}

.summary-total-box--expense {
    background: rgba(220, 38, 38, 0.08);
    border-color: rgba(220, 38, 38, 0.14);
}

.summary-total-box--expense strong {
    color: #b42318;
}

.summary-balance-strip-card {
    display: grid;
    gap: 20px;
}

.cash-box-card {
    display: grid;
    gap: 14px;
}

.cash-box-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
    border: 1px solid transparent;
}

.cash-box-badge.is-complete {
    background: #dcfce7;
    color: #166534;
    border-color: #a7f3d0;
}

.cash-box-badge.is-replenishable {
    background: #fef3c7;
    color: #92400e;
    border-color: #f7d58b;
}

.cash-box-badge.is-insufficient {
    background: #fee2e2;
    color: #b91c1c;
    border-color: #fecaca;
}

.cash-box-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.cash-box-metric {
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(180, 207, 221, 0.48);
    display: grid;
    gap: 6px;
}

.cash-box-metric span,
.cash-box-metric small {
    color: var(--muted);
}

.cash-box-metric span {
    font-size: 0.85rem;
    font-weight: 700;
}

.cash-box-metric strong {
    color: var(--primary);
    font-size: 1.45rem;
    line-height: 1;
}

.cash-box-metric small {
    font-size: 0.8rem;
    line-height: 1.35;
}

.cash-box-metric--featured {
    background: rgba(232, 244, 220, 0.8);
    border-color: rgba(126, 183, 89, 0.35);
}

.cash-box-metric--featured strong {
    color: #2f6b1f;
}

.cash-box-metric--result {
    background: rgba(238, 242, 255, 0.88);
    border-color: rgba(126, 147, 240, 0.3);
}

.cash-box-grid > .cash-box-metric:nth-child(1) {
    order: 1;
}

.cash-box-grid > .cash-box-metric:nth-child(2) {
    order: 2;
    background: rgba(236, 244, 255, 0.96);
    border-color: rgba(101, 146, 240, 0.24);
}

.cash-box-grid > .cash-box-metric:nth-child(4) {
    order: 3;
    background: rgba(254, 249, 195, 0.75);
    border-color: rgba(234, 179, 8, 0.24);
}

.cash-box-grid > .cash-box-metric:nth-child(5) {
    order: 4;
    background: rgba(220, 252, 231, 0.9);
    border-color: rgba(34, 197, 94, 0.22);
}

.cash-box-grid > .cash-box-metric:nth-child(5) strong {
    color: #166534;
    font-size: clamp(1.85rem, 2.7vw, 2.45rem);
}

.cash-box-grid > .cash-box-metric:nth-child(3) {
    order: 5;
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.92);
}

.cash-box-grid > .cash-box-metric:nth-child(3)::before {
    content: "\f0d6";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    width: 40px;
    height: 40px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #2f6b1f;
    background: rgba(220, 252, 231, 0.9);
    border: 1px solid rgba(34, 197, 94, 0.18);
    flex: 0 0 40px;
}

.cash-box-grid > .cash-box-metric:nth-child(3) span {
    font-size: 0.8rem;
}

.cash-box-grid > .cash-box-metric:nth-child(3) strong {
    margin-left: auto;
    font-size: 1.15rem;
}

.cash-box-grid > .cash-box-metric:nth-child(3) small {
    display: none;
}

.cash-box-movements {
    display: grid;
    gap: 10px;
    padding-top: 2px;
    border-top: 1px solid rgba(180, 207, 221, 0.35);
}

.cash-box-movements-header {
    display: grid;
    gap: 4px;
}

.cash-box-movements-header strong {
    color: var(--primary);
}

.cash-box-movements-header span,
.cash-box-empty-copy {
    color: var(--muted);
    font-size: 0.88rem;
}

.cash-box-movements-list {
    display: grid;
    gap: 8px;
}

.cash-box-movement-item {
    position: relative;
    display: grid;
    grid-template-columns: 14px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(180, 207, 221, 0.42);
}

.cash-box-movement-item::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: #f4b740;
    box-shadow: 0 0 0 4px rgba(244, 183, 64, 0.15);
}

.cash-box-movement-item--reposicion::before,
.cash-box-movement-item--reposicion_efectivo_dia::before,
.cash-box-movement-item--completar_caja_chica::before {
    background: #4a5ba8;
    box-shadow: 0 0 0 4px rgba(74, 91, 168, 0.15);
}

.cash-box-movement-item--ajuste::before {
    background: #64748b;
    box-shadow: 0 0 0 4px rgba(100, 116, 139, 0.14);
}

.cash-box-movement-item--salida_operativa::before,
.cash-box-movement-item--pago_tercero_caja_chica::before {
    background: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.14);
}

.cash-box-movement-copy {
    display: grid;
    gap: 2px;
}

.cash-box-movement-copy strong {
    color: var(--primary);
    font-size: 0.95rem;
}

.cash-box-movement-copy span {
    color: var(--muted);
    font-size: 0.82rem;
}

.cash-box-movement-amount {
    flex: 0 0 auto;
    color: var(--primary);
    font-size: 1rem;
    font-weight: 700;
    white-space: nowrap;
}

.cash-box-history-note {
    margin: -4px 0 0;
}

.cash-box-forms-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
}

.cash-box-form {
    padding: 12px 14px;
    border-radius: 18px;
    background: rgba(248, 250, 255, 0.72);
    border: 1px solid rgba(180, 207, 221, 0.4);
}

.cash-box-form-header {
    margin-bottom: 6px;
}

.cash-box-form-grid {
    gap: 10px;
}

.cash-box-form-grid .full-width {
    grid-column: 1 / -1;
}

.cash-box-collapsible {
    padding: 0;
    overflow: hidden;
}

.cash-box-collapsible-summary {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}

.cash-box-collapsible-summary::-webkit-details-marker {
    display: none;
}

.cash-box-collapsible-summary span {
    color: var(--primary);
    font-weight: 700;
}

.cash-box-collapsible-summary small {
    color: var(--muted);
    font-size: 0.82rem;
}

.cash-box-collapsible-summary::after {
    content: "\f078";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    color: var(--secondary);
    transition: transform 0.2s ease;
}

.cash-box-collapsible[open] .cash-box-collapsible-summary::after {
    transform: rotate(180deg);
}

.cash-box-collapsible-body {
    padding: 0 14px 14px;
}

.cash-box-form-grid--compact input,
.cash-box-form-grid--compact select {
    min-height: 42px;
    padding-top: 10px;
    padding-bottom: 10px;
}

.cash-box-form-actions .btn {
    min-height: 38px;
    padding: 10px 14px;
}

.summary-balance-strip {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 14px;
    align-items: stretch;
}

.summary-balance-box {
    min-height: 124px;
    border-radius: 22px;
    padding: 18px 20px;
    display: grid;
    gap: 8px;
    align-content: center;
    border: 1px solid rgba(85, 156, 173, 0.18);
    background: rgba(255, 255, 255, 0.66);
}

.summary-balance-box span {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
}

.summary-balance-box strong {
    font-size: clamp(1.7rem, 2.8vw, 2.4rem);
    line-height: 1;
    color: var(--primary);
}

.summary-balance-box.income {
    background: rgba(22, 163, 74, 0.08);
    border-color: rgba(22, 163, 74, 0.18);
}

.summary-balance-box.income strong {
    color: #166534;
}

.summary-balance-box.expense {
    background: rgba(220, 38, 38, 0.08);
    border-color: rgba(220, 38, 38, 0.16);
}

.summary-balance-box.expense strong {
    color: #b42318;
}

.summary-balance-box.final {
    background: rgba(74, 88, 153, 0.1);
    border-color: rgba(74, 88, 153, 0.18);
}

.summary-balance-box.final.positive strong {
    color: #304a9a;
}

.summary-balance-box.final.negative strong {
    color: #b42318;
}

.summary-balance-box.cash-free {
    background: rgba(22, 163, 74, 0.1);
    border-color: rgba(22, 163, 74, 0.22);
}

.summary-balance-box.cash-free strong {
    color: #166534;
    font-size: clamp(1.95rem, 3vw, 2.7rem);
}

.summary-balance-operator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary);
    font-size: 1.8rem;
    font-weight: 700;
}

.cash-box-balance-note,
.cash-box-warning-note {
    margin: 0;
}

.cash-box-warning-note {
    color: #b42318;
    font-weight: 700;
}

.summary-legacy-balance-card,
.summary-legacy-cash-card,
.summary-legacy-operational-balance {
    display: none !important;
}

.summary-balance-strip-card--active {
    border: 1px solid rgba(85, 156, 173, 0.18);
}

.summary-balance-strip-card--active .summary-block-header {
    align-items: center;
}

.summary-operational-card {
    display: grid;
    gap: 14px;
    border: 1px solid rgba(85, 156, 173, 0.18);
}

.summary-operational-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.summary-operational-kpi {
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(190, 220, 230, 0.9);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 6px 18px rgba(38, 55, 90, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 88px;
    position: relative;
    overflow: hidden;
}

.summary-operational-kpi span {
    flex: 1 1 auto;
    color: #736278;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1.25;
    white-space: normal;
    word-break: normal;
    overflow-wrap: normal;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
}

.summary-operational-kpi strong {
    flex: 0 0 auto;
    color: #4a5899;
    font-size: clamp(20px, 2vw, 28px);
    line-height: 1;
    text-align: right;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.summary-operational-kpi::before {
    content: none;
}

.summary-operational-kpi.cash-day {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(190, 220, 230, 0.9);
}

.summary-operational-kpi.cash-day strong {
    color: #4a5899;
}

.summary-operational-kpi.cash-current {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(190, 220, 230, 0.9);
}

.summary-operational-kpi.cash-current strong {
    color: #4a5899;
}

.summary-operational-kpi.cash-reserved {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(190, 220, 230, 0.9);
}

.summary-operational-kpi.cash-reserved strong {
    color: #4a5899;
}

.summary-operational-kpi-action {
    margin-top: 0;
}

.summary-operational-kpi.cash-free {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(190, 220, 230, 0.9);
    box-shadow: 0 6px 18px rgba(38, 55, 90, 0.05);
}

.summary-operational-kpi.cash-free strong {
    color: #4a5899;
    font-size: clamp(20px, 2vw, 28px);
}

.summary-operational-status {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 16px;
    padding: 16px 18px;
    border-radius: 20px;
    border: 1px solid rgba(180, 207, 221, 0.42);
    background: rgba(248, 250, 255, 0.92);
}

.summary-operational-status--complete {
    background: linear-gradient(135deg, rgba(236, 253, 245, 0.98) 0%, rgba(220, 252, 231, 0.86) 100%);
    border-color: rgba(34, 197, 94, 0.22);
}

.summary-operational-status--replenishable {
    background: rgba(220, 38, 38, 0.08);
    border-color: rgba(220, 38, 38, 0.16);
}

.summary-operational-status--insufficient {
    background: rgba(254, 226, 226, 0.72);
    border-color: rgba(239, 68, 68, 0.18);
}

.summary-operational-status-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.92);
    color: #b42318;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}

.summary-operational-status-icon i {
    font-size: 1.18rem;
}

.summary-operational-status--complete .summary-operational-status-icon {
    color: #16a34a;
}

.summary-operational-status--replenishable .summary-operational-status-icon {
    color: #b45309;
}

.summary-operational-status--insufficient .summary-operational-status-icon {
    color: #dc2626;
}

.summary-operational-status-copy {
    display: grid;
    gap: 4px;
}

.summary-operational-status-copy strong {
    color: var(--primary);
    font-size: 1rem;
    line-height: 1.15;
}

.summary-operational-status-copy span {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.35;
}

.summary-operational-status-detail {
    display: grid;
    gap: 4px;
    justify-items: end;
    text-align: right;
    color: var(--muted);
    font-size: 0.82rem;
    white-space: nowrap;
}

.summary-operational-status-action {
    display: flex;
    justify-content: flex-end;
}

.summary-operational-meta {
    display: none !important;
}

.summary-operational-meta-item {
    color: var(--muted);
    font-size: 0.88rem;
    font-weight: 700;
}

.cash-box-actions-row {
    display: none !important;
}

.cash-box-actions-row form {
    display: none !important;
}

.summary-operational-status-action .summary-operational-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 10px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(74, 91, 168, 0.3);
    color: #304a9a;
    box-shadow: 0 4px 12px rgba(74, 91, 168, 0.06);
    width: auto;
    white-space: nowrap;
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.summary-operational-status-action .summary-operational-cta:hover,
.summary-operational-status-action .summary-operational-cta:focus-visible {
    background: #f3f6ff;
    color: #304a9a;
    border-color: rgba(48, 74, 154, 0.58);
    box-shadow: 0 8px 18px rgba(74, 91, 168, 0.09);
    transform: none;
}

.summary-operational-status-action .summary-operational-cta:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px rgba(74, 91, 168, 0.16),
        0 8px 18px rgba(74, 91, 168, 0.09);
}

.summary-operational-status-action .summary-operational-cta:active {
    background: #edf2ff;
    color: #304a9a;
    border-color: rgba(48, 74, 154, 0.64);
    box-shadow: 0 4px 10px rgba(74, 91, 168, 0.1);
    transform: scale(0.985);
}

.summary-operational-status-action .summary-operational-cta i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 999px;
    font-size: 0.92rem;
    color: currentColor;
    background: transparent;
    border: 1px solid transparent;
    line-height: 1;
    flex-shrink: 0;
}

.summary-operational-status-action .summary-operational-cta .fa,
.summary-operational-status-action .summary-operational-cta .fa-solid,
.summary-operational-status-action .summary-operational-cta .btn-icon,
.summary-operational-status-action .summary-operational-cta .button-icon,
.summary-operational-status-action .summary-operational-cta .icon-circle,
.summary-operational-status-action .summary-operational-cta .btn-icon-circle {
    color: currentColor;
    background: transparent;
    box-shadow: none;
    border-color: transparent;
}

.summary-operational-movements {
    gap: 8px;
}

.summary-operational-weekly {
    display: grid;
    gap: 16px;
    padding: 18px 18px 16px;
    border-radius: 24px;
    border: 1px solid rgba(34, 197, 94, 0.18);
    background: linear-gradient(180deg, rgba(242, 252, 247, 0.98) 0%, rgba(237, 250, 244, 0.94) 100%);
}

.summary-operational-weekly-header {
    margin-bottom: 0;
    align-items: start;
}

.summary-operational-weekly-body {
    display: grid;
    grid-template-columns: minmax(280px, 304px) minmax(0, 1fr);
    gap: 6px;
    align-items: stretch;
}

.summary-operational-weekly-days {
    display: grid;
    gap: 8px;
}

.summary-operational-weekly-total {
    display: grid;
    align-content: center;
    gap: 14px;
    min-height: 180px;
    padding: 24px 24px 22px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(246, 255, 250, 0.96) 100%);
    border: 1px solid rgba(186, 230, 207, 0.82);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.summary-operational-weekly-total span {
    color: #2f3c6a;
    font-size: 0.92rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.summary-operational-weekly-total strong {
    color: #166534;
    font-size: clamp(2.6rem, 3.4vw, 3.35rem);
    line-height: 0.98;
}

.summary-operational-weekly-total small {
    color: #6b7280;
    font-size: 0.98rem;
    line-height: 1.38;
}

.summary-operational-weekly-total.negative {
    border-color: rgba(220, 38, 38, 0.14);
    box-shadow: 0 12px 28px rgba(220, 38, 38, 0.07);
}

.summary-operational-weekly-total.negative strong {
    color: #b42318;
}

.summary-operational-weekly-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 8px;
}

.summary-operational-weekly-item {
    min-height: 116px;
    padding: 14px 14px 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(220, 232, 238, 0.92);
    display: grid;
    align-content: space-between;
    gap: 6px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.summary-operational-weekly-day {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.summary-operational-weekly-label {
    color: #2f3c6a;
    font-weight: 700;
    font-size: 1rem;
}

.summary-operational-weekly-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 20px;
    padding: 1px 7px;
    border-radius: 999px;
    background: rgba(34, 197, 94, 0.16);
    color: #15803d;
    font-size: 0.68rem;
    font-weight: 700;
}

.summary-operational-weekly-item small {
    color: #667085;
    font-size: 0.9rem;
    line-height: 1.2;
}

.summary-operational-weekly-item strong {
    color: #166534;
    font-size: 1.08rem;
    line-height: 1.05;
}

.summary-operational-weekly-item.is-negative strong {
    color: #b42318;
}

.summary-operational-weekly-item.is-today {
    background: linear-gradient(180deg, rgba(236, 253, 245, 1) 0%, rgba(248, 255, 251, 0.96) 100%);
    border-color: rgba(134, 239, 172, 0.88);
    box-shadow: 0 0 0 2px rgba(187, 247, 208, 0.82);
}

.summary-operational-weekly-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
    border-radius: 16px;
    background: rgba(247, 255, 250, 0.96);
    border: 1px solid rgba(186, 230, 207, 0.82);
}

.summary-operational-weekly-footer span {
    color: #2f3c6a;
    font-size: 0.96rem;
    font-weight: 700;
    text-transform: none;
}

.summary-operational-weekly-footer strong {
    color: #166534;
    font-size: 1.1rem;
}

.summary-operational-weekly-footer.negative {
    border-color: rgba(220, 38, 38, 0.16);
}

.summary-operational-weekly-footer.negative strong {
    color: #b42318;
}

.summary-closing-actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 8px;
    border-top: 1px solid rgba(180, 207, 221, 0.35);
}

.summary-closing-actions .btn {
    font-size: 0.98rem;
    background: #4a5ba8;
    color: #ffffff;
    border: 1px solid rgba(74, 91, 168, 0.72);
    box-shadow: 0 8px 18px rgba(74, 91, 168, 0.16);
}

.summary-closing-actions .btn:hover,
.summary-closing-actions .btn:focus-visible {
    background: #3f4f97;
    color: #ffffff;
    border-color: rgba(63, 79, 151, 0.92);
    box-shadow: 0 10px 22px rgba(74, 91, 168, 0.2);
    transform: translateY(-1px);
}

.summary-closing-actions .btn:active {
    background: #374687;
    color: #ffffff;
    border-color: rgba(55, 70, 135, 0.94);
    box-shadow: 0 6px 14px rgba(74, 91, 168, 0.16);
    transform: scale(0.985);
}

.summary-closing-actions .btn:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px rgba(74, 91, 168, 0.18),
        0 10px 22px rgba(74, 91, 168, 0.2);
}

.summary-closing-actions .btn::after {
    content: none;
}

.expense-cash-box-card,
.expense-cash-box-log-card {
    border: 1px solid rgba(85, 156, 173, 0.18);
}

.expense-records-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 24px;
    align-items: stretch;
}

.expense-records-grid > .table-card,
.expense-records-grid > .expense-dual-card,
.expense-records-grid > .content-card {
    grid-column: auto !important;
    width: 100%;
}

.expense-entry-card,
.expense-cash-box-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.expense-entry-form {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
}

.expense-entry-form .form-grid {
    flex: 1;
    align-content: start;
}

.expense-entry-actions {
    margin-top: auto;
    justify-content: flex-end;
    align-items: flex-end;
    padding-top: 12px;
}

.expense-entry-actions .btn {
    align-self: flex-end;
}

.expense-dual-card {
    min-width: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.expense-cash-box-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: fit-content;
    min-width: 150px;
    min-height: 46px;
    padding: 0.85rem 1.1rem;
    border-radius: 14px;
    background: #4a5ba8;
    color: #ffffff;
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1;
    border: 1px solid rgba(74, 91, 168, 0.72);
    box-shadow: 0 8px 18px rgba(74, 91, 168, 0.16);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.expense-cash-box-card .expense-cash-box-submit:hover,
.expense-cash-box-card .expense-cash-box-submit:focus-visible {
    background: #3f4f97;
    color: #ffffff;
    border-color: rgba(63, 79, 151, 0.92);
    box-shadow: 0 10px 22px rgba(74, 91, 168, 0.2);
    transform: translateY(-1px);
}

.expense-cash-box-card .expense-cash-box-submit:active {
    background: #374687;
    color: #ffffff;
    border-color: rgba(55, 70, 135, 0.94);
    box-shadow: 0 6px 14px rgba(74, 91, 168, 0.16);
    transform: scale(0.985);
}

.expense-cash-box-card .expense-cash-box-submit:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px rgba(74, 91, 168, 0.18),
        0 10px 22px rgba(74, 91, 168, 0.2);
}

.expense-cash-box-card .expense-cash-box-submit {
    background: var(--color-button-primary, var(--color-primary));
    color: var(--color-button-primary-color, #fff);
    border-color: var(--color-button-primary, var(--color-primary));
}

.expense-cash-box-card .expense-cash-box-submit:hover {
    background: var(--color-button-primary-hover, var(--color-primary-hover));
    color: var(--color-button-primary-color, #fff);
    border-color: var(--color-button-primary-hover, var(--color-primary-hover));
}

.expense-cash-box-card .expense-cash-box-submit i,
.expense-cash-box-card .expense-cash-box-submit .fa,
.expense-cash-box-card .expense-cash-box-submit .fa-solid {
    color: currentColor;
}

.expense-cash-box-card .expense-cash-box-submit i {
    font-size: 0.95rem;
    flex: 0 0 auto;
}

.expense-cash-box-timeline {
    display: grid;
    gap: 8px;
    flex: 1;
    min-height: 0;
    max-height: 520px;
    overflow-y: auto;
    padding-right: 4px;
}

.expense-cash-box-item {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(180, 207, 221, 0.42);
    background: rgba(255, 255, 255, 0.9);
}

.expense-cash-box-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(180, 207, 221, 0.36);
}

.expense-cash-box-icon i {
    font-size: 0.96rem;
}

.expense-cash-box-copy {
    display: grid;
    gap: 2px;
}

.expense-cash-box-copy strong {
    color: var(--primary);
    font-size: 0.94rem;
    line-height: 1.2;
}

.expense-cash-box-copy span,
.expense-cash-box-copy small {
    color: var(--muted);
}

.expense-cash-box-copy span {
    font-size: 0.84rem;
    line-height: 1.3;
}

.expense-cash-box-copy small {
    font-size: 0.78rem;
    line-height: 1.25;
}

.expense-cash-box-amount {
    font-weight: 700;
    white-space: nowrap;
    text-align: right;
}

.expense-cash-box-item--reposicion .expense-cash-box-amount,
.expense-cash-box-item--reposicion_efectivo_dia .expense-cash-box-amount,
.expense-cash-box-item--completar_caja_chica .expense-cash-box-amount {
    color: #15803d;
}

.expense-cash-box-item--reposicion .expense-cash-box-icon,
.expense-cash-box-item--reposicion_efectivo_dia .expense-cash-box-icon,
.expense-cash-box-item--completar_caja_chica .expense-cash-box-icon {
    background: rgba(220, 252, 231, 0.9);
    border-color: rgba(34, 197, 94, 0.18);
    color: #15803d;
}

.expense-cash-box-item--vuelto .expense-cash-box-amount,
.expense-cash-box-item--vuelto_caja_chica .expense-cash-box-amount {
    color: #b45309;
}

.expense-cash-box-item--vuelto .expense-cash-box-icon,
.expense-cash-box-item--vuelto_caja_chica .expense-cash-box-icon {
    background: rgba(255, 247, 237, 0.94);
    border-color: rgba(245, 158, 11, 0.2);
    color: #c2410c;
}

.expense-cash-box-item--salida_operativa .expense-cash-box-amount,
.expense-cash-box-item--pago_tercero_caja_chica .expense-cash-box-amount {
    color: #b42318;
}

.expense-cash-box-item--salida_operativa .expense-cash-box-icon,
.expense-cash-box-item--pago_tercero_caja_chica .expense-cash-box-icon {
    background: rgba(254, 242, 242, 0.94);
    border-color: rgba(239, 68, 68, 0.18);
    color: #dc2626;
}

.expense-latest-expenses-card .table-scroll-area {
    display: flex;
    flex: 1;
    min-height: 0;
}

.expense-latest-table-shell {
    display: flex;
    flex: 1;
    overflow-y: auto;
}

.expense-latest-table-shell .data-table {
    height: 100%;
}

.expense-latest-expenses-card .data-table th,
.expense-latest-expenses-card .data-table td {
    padding-top: 9px;
    padding-bottom: 9px;
}

.expense-latest-expenses-card .data-table td:nth-child(3) {
    text-align: right;
    white-space: nowrap;
}

.expense-latest-expenses-card {
    gap: 12px;
    min-height: 0;
}

.expense-latest-legacy-views {
    display: none !important;
}

.expense-latest-list-shell {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 8px;
    margin-right: -4px;
    scrollbar-width: thin;
    scrollbar-color: rgba(74, 88, 153, 0.24) transparent;
}

.expense-latest-list-shell::-webkit-scrollbar {
    width: 8px;
}

.expense-latest-list-shell::-webkit-scrollbar-track {
    background: transparent;
}

.expense-latest-list-shell::-webkit-scrollbar-thumb {
    background: rgba(74, 88, 153, 0.22);
    border-radius: 999px;
}

.expense-latest-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 8px;
}

.expense-latest-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 18px;
    border: 1px solid rgba(201, 220, 233, 0.95);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(40, 55, 90, 0.05);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.expense-latest-item:hover {
    transform: translateY(-1px);
    border-color: rgba(164, 194, 230, 0.95);
    box-shadow: 0 14px 26px rgba(40, 55, 90, 0.08);
}

.expense-latest-item-main {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    flex: 1;
}

.expense-latest-icon {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 20px;
}

.expense-latest-icon--detergent {
    color: #3059c8;
    background: #edf3ff;
}

.expense-latest-icon--gas {
    color: #d97706;
    background: #fff4df;
}

.expense-latest-icon--rent {
    color: #7c3aed;
    background: #f3ebff;
}

.expense-latest-icon--third-party {
    color: #0f766e;
    background: #e7fbf7;
}

.expense-latest-icon--light {
    color: #ca8a04;
    background: #fff7db;
}

.expense-latest-icon--default {
    color: #4a5899;
    background: #eef2ff;
}

.expense-latest-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.expense-latest-title {
    font-size: 1rem;
    line-height: 1.25;
    color: #1f2a5a;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.expense-latest-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    color: #736278;
    font-size: 0.9rem;
    line-height: 1.35;
}

.expense-latest-laundry-pill {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 12px;
    border-radius: 999px;
    background: #eef4ff;
    color: #4a5899;
    font-size: 0.82rem;
    font-weight: 700;
}

.expense-latest-item-side {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.expense-latest-amount {
    color: #4a5899;
    font-size: clamp(1.3rem, 2vw, 1.8rem);
    line-height: 1;
    font-weight: 700;
    text-align: right;
    white-space: nowrap;
}

.expense-latest-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
}

.expense-latest-actions form {
    margin: 0;
}

.expense-latest-empty-state {
    flex: 1;
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #736278;
    border: 1px dashed rgba(196, 214, 231, 0.95);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.72);
    padding: 20px;
}

.expense-modal-legacy-views {
    display: none !important;
}

.expense-modal-list-shell {
    margin-top: 8px;
}

.expense-modal-expense-list {
    gap: 10px;
}

.expense-modal-expense-item {
    padding: 15px 16px;
}

.expenses-history-card {
    display: flex;
    flex-direction: column;
    min-height: 520px;
}

.expenses-history-table-wrap {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.expenses-history-table {
    width: 100%;
}

.expenses-bottom-grid {
    align-items: stretch;
}

.expenses-bottom-grid .expenses-history-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.expenses-bottom-grid .expenses-history-card .expenses-history-table-wrap,
.expenses-bottom-grid .expenses-history-card .table-scroll-area,
.expenses-bottom-grid .expenses-history-card .table-responsive,
.expenses-bottom-grid .expenses-history-card .expenses-list-wrapper {
    display: flex;
    flex: 1;
    min-height: 0;
    max-height: none !important;
    height: auto !important;
    overflow-y: auto;
}

.expenses-bottom-grid .expenses-history-card table {
    width: 100%;
}

@media (max-width: 1080px) {
    .expense-latest-item {
        padding: 15px 16px;
    }
}

@media (max-width: 767px) {
    .expense-latest-list-shell {
        padding-right: 4px;
        margin-right: 0;
    }

    .expense-latest-item {
        align-items: flex-start;
        flex-direction: column;
        gap: 14px;
        border-radius: 20px;
    }

    .expense-latest-item-side {
        width: 100%;
        align-items: flex-start;
        gap: 10px;
    }

    .expense-latest-amount {
        width: 100%;
        text-align: left;
        font-size: 1.45rem;
    }

    .expense-latest-actions {
        width: 100%;
        justify-content: flex-start;
    }
}

.summary-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 12px;
    align-items: center;
}

.summary-legend-item {
    display: inline-flex;
    align-items: center;
}

@media (max-width: 1080px) {
    .expense-records-grid {
        grid-template-columns: 1fr;
    }

    .cash-box-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cash-box-forms-grid {
        grid-template-columns: 1fr;
    }

    .summary-operational-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .summary-operational-status {
        grid-template-columns: 1fr;
        justify-items: start;
    }

    .summary-operational-status-detail {
        justify-items: start;
        text-align: left;
    }

    .summary-operational-status-action {
        justify-content: flex-start;
    }

    .summary-operational-weekly-total {
        justify-items: start;
        text-align: left;
    }

    .summary-operational-weekly-body {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .summary-operational-weekly-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .summary-operational-weekly-footer {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 700px) {
    .expense-records-grid {
        gap: 14px;
    }

    .cash-box-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cash-box-movement-item {
        grid-template-columns: 14px minmax(0, 1fr);
    }

    .cash-box-movement-amount {
        grid-column: 2;
    }

    .cash-box-grid > .cash-box-metric:nth-child(3) {
        grid-column: 1 / -1;
    }

    .summary-operational-kpis {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .summary-operational-kpi {
        padding: 14px 16px;
    }

    .summary-operational-kpi.cash-reserved {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .summary-operational-kpi.cash-reserved strong,
    .summary-operational-kpi-action {
        grid-column: 1;
    }

    .summary-operational-kpi-action {
        margin-top: 8px;
    }

    .summary-operational-kpi.cash-free strong {
        font-size: 2.2rem;
    }

    .summary-operational-status {
        padding: 14px;
        gap: 10px;
    }

    .summary-operational-weekly {
        padding: 18px 16px;
    }

    .summary-operational-weekly-body {
        gap: 14px;
    }

    .summary-operational-weekly-total {
        padding: 18px 18px 16px;
    }

    .summary-operational-status-icon {
        width: 40px;
        height: 40px;
    }

    .summary-closing-actions {
        justify-content: stretch;
    }

    .summary-closing-actions > * {
        width: 100%;
    }

    .expense-cash-box-item {
        grid-template-columns: 38px minmax(0, 1fr);
        gap: 10px;
    }

    .expense-cash-box-amount {
        grid-column: 2;
    }

    .summary-operational-weekly-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.daily-total-result {
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.daily-total-result strong {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
}

.daily-total-result span {
    font-size: 12px;
    opacity: 0.7;
}

.daily-total-result.positive strong {
    color: #16a34a;
}

.daily-total-result.negative strong {
    color: #dc2626;
}

.closure-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    width: 100%;
}

.closure-type-summary {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.closure-type-badge {
    font-weight: 700;
}

.closure-type-badge--manual {
    background: rgba(220, 252, 231, 0.95);
    color: #166534;
}

.closure-type-badge--automatico {
    background: rgba(254, 243, 199, 0.98);
    color: #92400e;
}

.closure-automatic-note {
    margin: 0 0 14px;
    color: #7c5a16;
}

.closure-summary-item {
    padding: 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.closure-summary-item span {
    display: block;
    font-size: 13px;
    font-weight: 500;
    opacity: 0.7;
    margin-bottom: 6px;
}

.closure-summary-item strong {
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.3px;
    color: var(--primary);
}

.closure-summary-item.total.positive strong {
    color: #16a34a;
}

.closure-summary-item.total.negative strong {
    color: #dc2626;
}

.search-info-grid {
    display: grid;
    gap: 16px;
    width: 100%;
}

.search-info-grid--client {
    margin-top: 24px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.client-info-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(200px, 1fr));
    gap: 16px 20px;
    width: 100%;
    margin-top: 16px;
}

.client-info-grid .info-item {
    width: 100%;
}

.search-info-grid--order {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

[data-search-order-card] > .section-header:has(+ .search-info-grid--order) {
    margin-bottom: 12px;
}

.section-header-title-stack {
    display: flex;
    align-items: center;
    gap: var(--component-gap, 10px);
    flex-wrap: wrap;
}

.legacy-chip {
    background: #fff2e2;
    color: #9a5a14;
    border: 1px solid #f4d4aa;
}

.header-orden-antigua {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.header-orden-antigua .btn {
    margin-top: 4px;
    flex-shrink: 0;
}

.code-with-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.code-with-chip--stack {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.legacy-order-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    width: 100%;
    min-width: 0;
}

[data-search-order-card] .search-order-special-marks {
    display: contents;
}

.legacy-order-card-header .section-title {
    margin: 0;
    flex: 1;
    min-width: 0;
}

.legacy-order-card-header .legacy-chip,
.legacy-order-card-header .rectification-chip,
.legacy-order-card-header .order-voided-chip,
.legacy-order-card-header .order-regularized-chip,
.legacy-order-card-header .administrative-closure-chip,
.legacy-order-card-header .order-detail-audit-menu {
    flex-shrink: 0;
    align-self: center;
}

.legacy-order-indicator {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-left: 6px;
    border-radius: 999px;
    background: #fff4e5;
    color: #b7791f;
    border: 1px solid #f3d7b6;
    font-size: 11px;
    vertical-align: middle;
    flex-shrink: 0;
}

.legacy-order-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #fff4e5;
    border: 1px solid #f3d7b6;
    color: #b7791f;
    font-weight: 600;
    font-size: 13px;
    line-height: 1.2;
    white-space: nowrap;
    vertical-align: middle;
    cursor: help;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.legacy-order-pill i {
    font-size: 12px;
    opacity: 0.8;
    color: inherit;
}

.order-code-with-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.order-voided-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #ececec;
    border: 1px solid #d5d5d5;
    color: #5f6368;
    font-weight: 600;
    font-size: 13px;
    line-height: 1.2;
    white-space: nowrap;
    vertical-align: middle;
    cursor: help;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.order-voided-pill i {
    font-size: 12px;
    color: #6b7280;
    opacity: 0.82;
}

.order-code-special-pill,
.order-code-pill--regularized {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    line-height: 1.2;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    vertical-align: middle;
    cursor: help;
}

.order-code-pill--regularized {
    background: #eaf2ff;
    border: 1px solid #bfd4ff;
    color: #3156a3;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.order-code-pill--regularized .order-code-pill__text {
    line-height: 1;
}

.order-code-pill--regularized .order-code-pill__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #4f6fb8;
    line-height: 1;
    opacity: 0.82;
}

.order-voided-chip {
    background: #ececec;
    color: #5f6368;
    border: 1px solid #d5d5d5;
}

.order-regularized-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: #eaf2ff;
    color: #3156a3;
    border: 1px solid #bfd4ff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.status-chip.order-anulada {
    background: #ececec;
    color: #5f6368;
}

.rectification-chip {
    background: #f1e8ff;
    color: #7b3fc6;
    border: 1px solid #d9c2ff;
}

.administrative-closure-chip,
.administrative-closure-order-pill {
    background: #fff0f2;
    color: #9f283d;
    border: 1px solid #efb7c1;
}

.administrative-closure-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: fit-content;
    max-width: 100%;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

.administrative-closure-order-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 10px;
    border-radius: 999px;
}

.administrative-closure-banner {
    display: grid;
    grid-template-columns: minmax(150px, 180px) minmax(0, 1fr);
    align-items: center;
    column-gap: 20px;
    width: 100%;
    margin-bottom: 20px;
    padding: 12px 18px 12px 12px;
    border: 1px solid #efb7c1;
    border-radius: 12px;
    background: #fff5f6;
    color: #782033;
    box-sizing: border-box;
}

.administrative-closure-banner > .pill-chip {
    justify-self: center;
}

[data-search-order-card] .administrative-closure-banner {
    grid-template-columns: max-content minmax(0, 1fr);
    column-gap: 14px;
    margin-top: 8px;
    padding-left: 12px;
}

[data-search-order-card] .administrative-closure-banner > .pill-chip {
    justify-self: start;
    width: fit-content;
    max-width: 100%;
    padding-inline: 8px;
}

.administrative-closure-banner > div {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.administrative-closure-banner p,
.administrative-closure-banner strong,
.administrative-closure-banner small {
    margin: 0;
}

.administrative-closure-confirmation {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 14px 0 8px;
}

.administrative-closure-confirmation input {
    flex: 0 0 auto;
    margin-top: 3px;
}

@media (max-width: 767px) {
    .administrative-closure-banner {
        grid-template-columns: minmax(0, 1fr);
        row-gap: 8px;
    }

    .administrative-closure-banner > .pill-chip {
        justify-self: start;
    }

    [data-search-order-card] .administrative-closure-banner {
        grid-template-columns: minmax(0, 1fr);
        column-gap: 0;
    }
}

.rectification-order-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f1e8ff;
    border: 1px solid #d9c2ff;
    color: #7b3fc6;
    font-weight: 600;
    font-size: 13px;
    line-height: 1.2;
    white-space: nowrap;
    vertical-align: middle;
    cursor: help;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.rectification-order-pill i {
    font-size: 12px;
    opacity: 0.82;
    color: inherit;
}

.rectification-order-banner {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    margin-bottom: 18px;
    padding: 12px 16px;
    border-radius: 14px;
    background: #f8f1ff;
    border: 1px solid #ddcbff;
    color: #67527f;
}

.rectification-order-banner--card {
    margin-top: 12px;
    margin-bottom: 0;
}

.rectification-banner-chip {
    flex-shrink: 0;
    background: #ebddff;
    color: #7b3fc6;
    border: 1px solid #d5bbff;
}

.legacy-order-banner,
.banner-orden-antigua {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    width: 100%;
    padding: 12px 18px;
    border-radius: 12px;
    background: #fff6e9;
    border: 1px solid #f3d7b6;
    margin-bottom: 20px;
}

.legacy-order-banner .legacy-chip,
.banner-orden-antigua .chip {
    flex-shrink: 0;
    background: #ffe7c7;
    color: #b7791f;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    border: none;
}

.legacy-order-banner .legacy-text,
.banner-orden-antigua .texto {
    flex: 1;
    text-align: left;
    font-size: 13px;
    color: #7a6a58;
    line-height: 1.4;
}

.legacy-order-actions {
    margin-top: 18px;
}

.legacy-order-form {
    gap: 0;
}

.legacy-order-case-block {
    margin-bottom: 24px;
}

.rectification-page-card {
    display: grid;
    gap: 16px;
}

.rectification-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.rectification-header-topline {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.rectification-header-chip {
    text-transform: uppercase;
    letter-spacing: 0.03em;
    background: rgba(122, 99, 214, 0.12);
    color: #6a46c1;
    border: 1px solid rgba(122, 99, 214, 0.22);
    box-shadow: none;
}

.rectification-banner {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    width: 100%;
    padding: 12px 18px;
    border-radius: 14px;
    background: rgba(122, 99, 214, 0.12);
    border: 1px solid rgba(122, 99, 214, 0.22);
}

.rectification-banner-text {
    flex: 1;
    color: #7a6a58;
    font-size: 13px;
    line-height: 1.45;
    text-align: left;
}

.rectification-banner-chip {
    background: rgba(122, 99, 214, 0.12);
    color: #6a46c1;
    border: 1px solid rgba(122, 99, 214, 0.22);
    box-shadow: none;
    width: fit-content !important;
    min-width: auto !important;
    max-width: fit-content !important;

    padding: 6px 12px !important;

    margin: 0 !important;

    flex: 0 0 auto !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.rectification-form {
    display: grid;
    gap: 22px;
}

.rectification-block {
    display: grid;
    gap: 16px;
    padding: 20px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.68);
    border: 1px solid rgba(85, 156, 173, 0.16);
}

.rectification-inline-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: end;
}

.rectification-client-search {
    position: relative;
    max-width: 760px;
}

.client-search-empty {
    display: grid;
    gap: 10px;
    padding: 14px;
    color: var(--muted);
}

.client-search-empty-action {
    width: fit-content;
    border: 1px solid rgba(74, 88, 153, 0.28);
    border-radius: 999px;
    background: #fff;
    color: var(--primary);
    padding: 8px 12px;
    font-weight: 700;
    cursor: pointer;
}

.rectification-form-grid,
.rectification-finance-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.rectification-linked-order-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 300px);
    gap: 16px;
    align-items: end;
    padding-bottom: 2px;
}

.rectification-client-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.rectification-client-grid[hidden] {
    display: none !important;
}

#rectification-client-details[hidden] {
    display: none !important;
}

.rectification-preview-box {
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(248, 250, 255, 0.85);
    border: 1px solid rgba(180, 207, 221, 0.48);
    width: 100%;
    text-align: center;
}

.rectification-preview-box > * {
    margin-left: auto;
    margin-right: auto;
}

.rectification-original-action-group .btn {
    width: 100%;
}

.rectification-original-action-group .btn.is-disabled-soft {
    opacity: 0.62;
}

.rectification-linked-order-field {
    min-height: 48px;
    display: flex;
    align-items: center;
    padding: 8px 10px;
    border: 1px solid rgba(180, 207, 221, 0.78);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.9);
    box-sizing: border-box;
}

.rectification-linked-order-placeholder {
    color: var(--muted);
    font-size: 14px;
}

.rectification-linked-order-pill {
    max-width: 100%;
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 6px 4px 12px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.09);
    border: 1px solid rgba(74, 88, 153, 0.18);
    color: var(--primary);
    font-weight: 700;
}

.rectification-linked-order-pill[hidden],
.rectification-linked-order-placeholder[hidden] {
    display: none !important;
}

.rectification-linked-order-pill button {
    width: 24px;
    height: 24px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    color: inherit;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
}

.rectification-linked-order-pill button:hover {
    background: rgba(74, 88, 153, 0.14);
}

.rectification-original-preview {
    min-height: 24px;
}

.rectification-original-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 14px;
    background: rgba(241, 248, 255, 0.9);
    border: 1px solid rgba(180, 207, 221, 0.58);
    color: var(--primary);
}

.rectification-original-pill--muted {
    color: var(--muted);
    background: rgba(248, 239, 246, 0.48);
}

.rectification-orders-modal-shell {
    max-width: 980px;
}

.rectification-orders-modal-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-height: 440px;
}

.rectification-orders-search {
    position: relative;
    width: 100%;
    display: block;
    flex: 0 0 auto;
}

.rectification-orders-search .filter-search-icon {
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: #7f88b3;
    pointer-events: none;
    z-index: 2;
}

.rectification-orders-search input {
    width: 100%;
    min-height: 48px;
    padding: 12px 16px 12px 44px;
    border-radius: 14px;
    box-sizing: border-box;
}

.rectification-orders-list {
    display: grid;
    gap: 10px;
    flex: 1 1 auto;
    align-content: start;
}

.rectification-orders-list[hidden] {
    display: none !important;
}

.rectification-orders-empty[hidden] {
    display: none !important;
}

.rectification-orders-results-stage {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.rectification-order-card {
    border: 1px solid rgba(190, 220, 230, 0.9);
    border-radius: 18px;
    background: #fff;
    padding: 15px 16px;
    box-shadow: 0 6px 18px rgba(38, 55, 90, 0.05);
}

.rectification-order-card-head,
.rectification-order-card-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.rectification-order-card-head strong {
    color: var(--primary);
    font-size: 16px;
    line-height: 1.2;
}

.rectification-order-card-copy {
    min-width: 0;
}

.rectification-order-card-meta {
    display: flex;
    align-items: center;
    gap: 8px 10px;
    flex-wrap: wrap;
    margin-top: 6px;
}

.rectification-order-card-meta span,
.rectification-order-card-body span {
    display: inline-flex;
    align-items: center;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.3;
}

.rectification-order-card-body {
    margin-top: 12px;
    align-items: flex-end;
}

.rectification-order-services {
    min-width: 0;
    display: grid;
    gap: 8px;
}

.rectification-order-services-label {
    color: #736278;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.rectification-order-services-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.rectification-order-service-chip {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.08);
    border: 1px solid rgba(74, 88, 153, 0.14);
    color: #4a5899;
    font-size: 12px;
    line-height: 1.15;
    font-weight: 700;
}

.rectification-order-service-chip.is-empty {
    color: var(--muted);
    background: rgba(248, 250, 255, 0.92);
    border-color: rgba(190, 220, 230, 0.9);
}

.rectification-order-select-btn {
    width: auto;
    min-width: 132px;
    justify-content: center;
}

.rectification-orders-empty {
    display: grid;
    place-items: center;
    flex: 1 1 auto;
    min-height: 0;
    padding: 0;
}

.rectification-orders-empty-state {
    width: min(100%, 560px);
    display: grid;
    justify-items: center;
    gap: 14px;
    padding: 28px 24px;
    border-radius: 24px;
    border: 1px solid rgba(190, 220, 230, 0.9);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(248, 250, 255, 0.94) 100%);
    box-shadow: 0 16px 34px rgba(74, 88, 153, 0.08);
    text-align: center;
}

.rectification-orders-empty-icon {
    width: 56px;
    height: 56px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
    border: 1px solid rgba(85, 156, 173, 0.18);
    font-size: 22px;
}

.rectification-orders-empty-state h4 {
    margin: 0;
    color: var(--primary);
    font-size: 1.16rem;
    line-height: 1.3;
}

.rectification-orders-empty-state p {
    margin: 0;
    max-width: 44ch;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.6;
}

.rectification-orders-empty-hint {
    width: 100%;
    display: inline-flex;
    align-items: flex-start;
    justify-content: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(241, 248, 255, 0.92);
    border: 1px solid rgba(190, 220, 230, 0.78);
    color: #5f6f93;
    text-align: left;
}

.rectification-orders-empty-hint i {
    color: var(--primary);
    margin-top: 2px;
}

.rectification-orders-empty-hint span {
    font-size: 13px;
    line-height: 1.5;
}

#rectification-client-orders-modal .modal-header {
    text-align: left;
    align-items: flex-start;
}

#rectification-client-orders-modal .modal-header > div {
    min-width: 0;
    text-align: left;
}

#rectification-client-orders-modal .modal-header h3,
#rectification-client-orders-modal .modal-header p {
    text-align: left;
    margin-left: 0;
    margin-right: 0;
}

@media (max-width: 767px) {
    .rectification-orders-modal-body {
        min-height: 360px;
    }

    .rectification-orders-empty-state {
        width: 100%;
        padding: 24px 18px;
    }
}

.rectification-service-trigger {
    width: 100%;
    border: 1px dashed rgba(85, 156, 173, 0.45);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.rectification-service-trigger:hover {
    border-color: rgba(74, 88, 153, 0.38);
    box-shadow: 0 14px 28px rgba(74, 88, 153, 0.08);
    transform: translateY(-1px);
}

.rectification-service-trigger-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.rectification-service-trigger-copy strong {
    color: var(--primary);
    font-size: 16px;
}

.rectification-service-trigger-copy small {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.4;
}

.rectification-service-trigger-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.rectification-service-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    min-height: 38px;
}

.rectification-service-empty {
    color: var(--muted);
    font-size: 13px;
}

.rectification-service-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(194, 204, 232, 0.42);
}

.rectification-service-chip strong {
    color: var(--primary);
    font-size: 14px;
}

.rectification-finance-copy {
    margin: 0;
}

.rectification-services-modal-shell {
    width: min(900px, 94vw);
    height: auto !important;
    max-height: min(88vh, 820px) !important;
}

.rectification-services-modal-body {
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow-y: auto;
    overflow-x: hidden;
}

.rectification-service-option-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.rectification-service-option-card {
    display: flex;
    flex-direction: row;
    gap: 12px;
    padding: 16px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(252, 247, 251, 0.98) 100%);
    border: 1px solid rgba(85, 156, 173, 0.16);
    box-shadow: 0 10px 20px rgba(74, 88, 153, 0.06);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, transform 0.18s ease;
    cursor: pointer;
}

.rectification-service-option-card:hover {
    border-color: var(--color-button-outline-border);
    box-shadow: var(--shadow-soft);
    transform: translateY(-1px);
}

.rectification-service-option-card.is-active {
    border-color: var(--color-button-outline-border);
    background: color-mix(in srgb, var(--color-surface) 76%, white 24%);
    box-shadow: var(--shadow-soft);
}

.rectification-service-option-head {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    cursor: pointer;
}

.rectification-service-option-check {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    border: 1px solid rgba(85, 156, 173, 0.22);
    background: #fff;
    color: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.rectification-service-option-card.is-active .rectification-service-option-check {
    background: var(--secondary);
    border-color: var(--secondary);
    color: #fff;
}

.rectification-service-option-icon {
    width: 46px;
    height: 46px;
    border-radius: 16px;
    background: var(--color-button-outline-hover-bg);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1rem;
}

.rectification-service-option-card.is-active .rectification-service-option-icon {
    background: var(--color-button-outline-hover-bg);
    color: var(--primary);
}

.rectification-service-option-copy {
    display: grid;
    gap: 4px;
}

.rectification-service-option-copy strong {
    color: var(--primary);
    font-size: 15px;
}

.rectification-service-option-copy small {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.4;
}

.rectification-service-option-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-left: 36px;
}

.rectification-service-option-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.08);
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.rectification-service-modal-actions {
    justify-content: flex-end;
}

.legacy-resolution-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.legacy-resolution-card {
    border: 1px solid rgba(85, 156, 173, 0.18);
    background: rgba(255, 255, 255, 0.75);
    border-radius: 20px;
    padding: 18px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    text-align: left;
    transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.legacy-resolution-card:hover {
    transform: translateY(-1px);
    border-color: rgba(214, 58, 153, 0.28);
    box-shadow: 0 12px 24px rgba(79, 91, 170, 0.08);
}

.legacy-resolution-card.is-active {
    background: rgba(255, 240, 248, 0.85);
    border-color: rgba(214, 58, 153, 0.42);
    box-shadow: 0 16px 28px rgba(214, 58, 153, 0.12);
}

.legacy-resolution-icon {
    width: 44px;
    height: 44px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(79, 91, 170, 0.08);
    color: var(--primary);
    flex-shrink: 0;
    font-size: 1rem;
}

.legacy-resolution-card.is-active .legacy-resolution-icon {
    background: rgba(214, 58, 153, 0.14);
    color: var(--accent);
}

.legacy-resolution-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.legacy-resolution-copy strong {
    color: var(--primary);
    font-size: 1rem;
}

.legacy-resolution-copy small {
    color: var(--muted);
    line-height: 1.45;
    font-size: 0.92rem;
}

.legacy-order-grid {
    margin-top: 8px;
}

.legacy-order-summary-card {
    margin-top: 24px;
    padding: 20px 22px;
    border-radius: 20px;
    background: rgba(79, 91, 170, 0.06);
    border: 1px solid rgba(85, 156, 173, 0.18);
}

.legacy-order-summary-card h4 {
    margin: 0 0 8px;
    color: var(--primary);
    font-size: 1rem;
}

.legacy-order-summary-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.legacy-service-trigger {
    width: 100%;
    border: 1px dashed rgba(85, 156, 173, 0.34);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.78);
    padding: 16px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    text-align: left;
    transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.legacy-service-trigger:hover {
    border-color: rgba(214, 58, 153, 0.34);
    background: rgba(255, 248, 252, 0.88);
    box-shadow: 0 10px 22px rgba(79, 91, 170, 0.08);
}

.legacy-service-trigger-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.legacy-service-trigger-copy strong {
    color: var(--primary);
}

.legacy-service-trigger-copy small {
    color: var(--muted);
    line-height: 1.4;
}

.legacy-service-trigger-icon {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    background: rgba(79, 91, 170, 0.08);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.legacy-service-summary-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

.legacy-service-summary-empty {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(245, 247, 252, 0.75);
    color: var(--muted);
    border: 1px solid rgba(85, 156, 173, 0.12);
}

.legacy-service-summary-chip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(85, 156, 173, 0.16);
}

.legacy-service-summary-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.legacy-service-summary-copy strong {
    color: var(--primary);
}

.legacy-service-summary-copy span {
    color: var(--muted);
    font-size: 0.92rem;
}

.legacy-order-form [readonly],
.legacy-order-form input:disabled,
.legacy-order-form select:disabled {
    background: rgba(245, 247, 252, 0.92);
    color: var(--muted);
}

.legacy-service-selector-modal {
    width: min(900px, 94vw);
    height: auto !important;
    max-height: min(88vh, 820px) !important;
}

.legacy-service-selector-body {
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow-y: auto;
    overflow-x: hidden;
}

.legacy-service-selector-head {
    margin-bottom: 0;
}

.legacy-service-selector-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.legacy-service-select-card {
    width: 100%;
    border: 1px solid rgba(85, 156, 173, 0.16);
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(252, 247, 251, 0.98) 100%);
    box-shadow: 0 10px 20px rgba(74, 88, 153, 0.06);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.legacy-service-select-card:hover {
    border-color: var(--color-button-outline-border);
    box-shadow: var(--shadow-soft);
    transform: translateY(-1px);
}

.legacy-service-select-card.is-active {
    border-color: var(--color-button-outline-border);
    background: color-mix(in srgb, var(--color-surface) 76%, white 24%);
    box-shadow: var(--shadow-soft);
}

.legacy-service-select-card-check {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    border: 1px solid rgba(85, 156, 173, 0.22);
    background: #fff;
    color: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.legacy-service-select-card.is-active .legacy-service-select-card-check {
    background: var(--secondary);
    border-color: var(--secondary);
    color: #fff;
}

.legacy-service-selector-actions {
    justify-content: flex-end;
}

.info-item {
    min-width: 0;
    padding: 14px 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.info-item span {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    opacity: 0.65;
}

.info-item strong {
    min-width: 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
    overflow-wrap: anywhere;
    word-break: break-word;
}

.pill-chip,
.status-chip,
.amount-pill,
.loyalty-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.status-chip.order-pendiente {
    background: #fef3c7;
    color: #7c2d12;
}

.status-chip.order-listo {
    background: #ddf4f8;
    color: #164e63;
}

.status-chip.order-entregado {
    background: #e7e9f8;
    color: #2e3a8c;
}

.status-chip.payment-pendiente {
    background: #fef3c7;
    color: #7c2d12;
}

.status-chip.payment-cancelado {
    background: #dcfce7;
    color: #14532d;
}

.status-chip.pendiente {
    background: #fef3c7;
    color: #7c2d12;
}

.status-chip.cancelado {
    background: #dcfce7;
    color: #14532d;
}

.status-chip.listo {
    background: #ddf4f8;
    color: #164e63;
}

.status-chip.entregado {
    background: #e7e9f8;
    color: #2e3a8c;
}

.status-chip.third-party-pendiente {
    background: #fef3c7;
    color: #7c2d12;
}

.status-chip.third-party-pending-alert {
    background: #fee2e2;
    color: #991b1b;
}

.status-chip.third-party-entregado {
    background: #ddf4f8;
    color: #164e63;
}

.status-chip.third-party-pagado {
    background: #dcfce7;
    color: #14532d;
}

.payment-alert {
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}

.pending-payment {
    background: #fff7e6;
    color: #92400e;
    border: 1px solid #fad7a0;
    border-radius: 14px;
    padding: 10px 12px;
}

.paid-payment {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
    border-radius: 14px;
    padding: 10px 12px;
}

.payment-alert strong,
.table-payment-status {
    font-weight: 700;
}

.payment-alert span,
.payment-alert strong {
    color: inherit;
}

.payment-alert .status-chip {
    margin-top: auto;
    align-self: flex-start;
}

.payment-alert .pill-chip,
.payment-alert .amount-pill {
    margin-left: 0;
    margin-right: auto;
}

.payment-summary-chip {
    font-size: 11px;
    font-weight: 700;
}

.order-detail-actions {
    margin-top: 24px;
}

.order-detail-actions .btn-mark-ready-soft,
.order-detail-actions .whatsapp-quick-trigger,
.order-detail-actions .btn-secondary,
.order-detail-actions .btn[type="submit"] {
    min-height: 46px;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.delayed-orders-modal .history-table {
    min-width: 1080px;
}

.delayed-orders-modal-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.delayed-orders-table-shell,
.orders-total-table-shell {
    flex: 1;
    min-height: 0;
}

.orders-modal-standard {
    width: min(1280px, 94vw);
    height: auto;
    display: block;
    max-height: 88vh;
}

.orders-modal-standard .modal-body {
    display: block;
    height: auto;
    flex: unset;
    min-height: 0;
    padding-bottom: 0;
}

.orders-modal-standard .table-scroll-area {
    max-height: 67.3vh;
    overflow-x: auto;
    overflow-y: auto;
    height: auto;
    min-height: 0;
}

.orders-modal-standard table {
    margin-bottom: 0;
}

.orders-modal-standard .delayed-orders-modal-body {
    display: block;
    flex: unset;
}

.orders-modal-standard .delayed-orders-table-shell {
    flex: unset;
}

#otherPendingOrdersModal .modal-dialog.modal-content.delayed-orders-modal.orders-modal-standard {
    height: 90vh;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#otherPendingOrdersModal .delayed-orders-modal-body {
    display: flex !important;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    padding-bottom: 0;
}

#otherPendingOrdersModal .history-filters {
    flex: 0 0 auto;
}

#otherPendingOrdersModal .pending-other-filters {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 0.8fr auto;
    gap: 14px 16px;
    align-items: end;
}

#otherPendingOrdersModal .pending-other-filters .history-filter-group {
    min-width: 0;
}

#otherPendingOrdersModal .pending-other-filter-search input {
    width: 100%;
}

#otherPendingOrdersModal .pending-other-filter-actions {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

#otherPendingOrdersModal .pending-other-filter-actions .btn {
    width: auto;
    min-width: 180px;
    white-space: nowrap;
}

#otherPendingOrdersModal .pending-other-filters--no-laundry {
    grid-template-columns: 1.6fr 1fr 1fr auto;
}

#otherPendingOrdersModal .delayed-orders-table-shell {
    flex: 1 1 auto !important;
    min-height: 0;
    max-height: none !important;
    height: auto !important;
    overflow-x: auto;
    overflow-y: auto;
}

#otherPendingOrdersModal .table-wrapper {
    width: 100%;
}

#allOrdersModal .modal-dialog.modal-content.modal-orders-wide {
    width: 95vw !important;
    max-width: 1400px !important;
    height: 90vh !important;
    max-height: 90vh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
}

#allOrdersModal .modal-header {
    padding-inline: 1.75rem 4.5rem;
}

#allOrdersModal .modal-body {
    display: flex !important;
    flex-direction: column !important;
    gap: 18px;
    overflow: hidden !important;
    overflow-x: hidden !important;
    padding-top: 16px !important;
    padding-inline: 1.75rem;
}

#allOrdersModal .orders-total-filters {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 14px 16px;
    flex: 0 0 auto;
    align-items: end;
    padding: 2px 0 4px;
    grid-auto-flow: row;
}

#allOrdersModal .orders-total-filters .history-filter-group,
#allOrdersModal .orders-total-filters .orders-filter-actions {
    min-width: 0;
}

#allOrdersModal .orders-filter-search {
    grid-column: span 2;
}

#allOrdersModal .orders-filter-search > label {
    padding-top: 0 !important;
}

#allOrdersModal .orders-filter-date {
    grid-column: span 1;
}

#allOrdersModal .orders-filter-sort {
    grid-column: span 1;
}

#allOrdersModal .orders-filter-status {
    grid-column: span 1;
}

#allOrdersModal .orders-filter-payment,
#allOrdersModal .orders-filter-laundry {
    grid-column: span 2;
}

#allOrdersModal .orders-filter-actions {
    grid-column: span 2;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    align-self: end;
}

#allOrdersModal .orders-filter-actions .btn {
    width: 100%;
    min-width: 210px;
    margin-left: auto;
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-payment {
    grid-column: span 2;
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-actions {
    grid-column: span 1;
    justify-content: flex-start;
}

#allOrdersModal .orders-total-filters--no-laundry {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-search {
    grid-column: 1 / span 2;
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-date {
    grid-column: span 1;
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-sort,
#allOrdersModal .orders-total-filters--no-laundry .orders-filter-status,
#allOrdersModal .orders-total-filters--no-laundry .orders-filter-payment,
#allOrdersModal .orders-total-filters--no-laundry .orders-filter-actions {
    grid-column: span 1;
}

#allOrdersModal .orders-filter-void-status {
    display: none !important;
}

#allOrdersModal .orders-total-filters--no-laundry .orders-filter-actions .btn {
    width: 100%;
    min-width: 0;
    margin-left: 0;
}

#allOrdersModal .orders-total-filters label {
    font-size: 12px;
    font-weight: 700;
    color: rgba(67, 79, 137, 0.82);
}

#allOrdersModal .orders-total-filters input,
#allOrdersModal .orders-total-filters select {
    min-height: 48px;
}

#allOrdersModal .table-container,
#allOrdersModal .orders-total-table-shell {
    flex: 1 1 auto;
    min-height: 0;
    max-height: 55vh;
    overflow-x: auto !important;
    overflow-y: auto !important;
}

#allOrdersModal .table-wrapper {
    width: 100%;
    overflow-x: auto !important;
    overflow-y: auto !important;
}

#allOrdersModal table {
    width: 100%;
    min-width: 1200px;
}

#allOrdersModal .history-empty-state {
    flex: 0 0 auto;
}

.table-payment-status {
    display: inline-flex;
    align-items: center;
    border-radius: 14px;
    white-space: nowrap;
}

.history-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
}

.history-table th,
.history-table td {
    padding: 14px 12px;
    vertical-align: middle;
    text-align: center;
    line-height: 1.35;
}

.history-table th {
    font-weight: 700;
}

.history-table td {
    overflow-wrap: break-word;
}

.history-table .status-cell,
.history-table .amount-cell,
.history-table .action-cell {
    white-space: nowrap;
    overflow: visible;
}

.order-actions-menu {
    position: relative;
    display: inline-flex;
}

.order-actions-trigger {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    border: 1px solid #d8e7ef;
    background: #ffffff;
    color: #44539a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: none;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.order-actions-trigger:hover {
    background: #f7f5ff;
    border-color: #c8c1f0;
}

.order-actions-dropdown {
    position: fixed;
    width: 210px;
    max-height: min(320px, calc(100vh - 32px));
    overflow-y: auto;
    background: #ffffff;
    border: 1px solid #e3e8ef;
    border-radius: 14px;
    box-shadow: 0 14px 30px rgba(55, 48, 90, 0.16);
    padding: 8px;
    z-index: 9999;
}

.order-actions-dropdown.order-actions-dropdown--up {
    transform-origin: bottom right;
}

.order-actions-dropdown[hidden] {
    display: none;
}

.order-actions-item {
    width: 100%;
    border: 0;
    background: transparent;
    padding: 10px 12px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #33427f;
    font-weight: 600;
    cursor: pointer;
    text-align: left;
    text-decoration: none;
}

.order-actions-item:hover {
    background: #f7f5ff;
}

.order-actions-divider {
    height: 1px;
    margin: 6px 4px;
    background: rgba(148, 163, 184, 0.24);
}

.order-row-voided {
    opacity: 1;
}

.orders-void-filter-group {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
}

.orders-void-filter-btn {
    border: 1px solid rgba(148, 163, 184, 0.28);
    background: rgba(255, 255, 255, 0.88);
    color: #4b5563;
    border-radius: 999px;
    padding: 10px 14px;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.orders-void-filter-btn.is-active {
    background: rgba(74, 88, 153, 0.12);
    border-color: rgba(74, 88, 153, 0.32);
    color: #2e3a8c;
    box-shadow: 0 10px 18px rgba(74, 88, 153, 0.12);
}

.order-actions-item i {
    width: 16px;
    text-align: center;
    color: #5563a8;
}

.order-actions-dropdown .whatsapp-quick-trigger,
.order-actions-dropdown .whatsapp-quick-trigger:hover,
.order-actions-dropdown .whatsapp-quick-trigger:focus-visible,
.order-actions-dropdown .whatsapp-quick-trigger:active {
    width: 100%;
    min-width: 0;
    min-height: auto;
    padding: 10px 12px;
    justify-content: flex-start;
    gap: 10px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #33427f;
    box-shadow: none;
    transform: none;
}

.order-actions-dropdown .whatsapp-quick-trigger:hover,
.order-actions-dropdown .whatsapp-quick-trigger:focus-visible {
    background: rgba(37, 211, 102, 0.10);
    color: #12733c;
    outline: none;
}

.order-actions-dropdown .whatsapp-quick-trigger i {
    width: 16px;
    text-align: center;
    color: #5563a8;
}

.order-actions-dropdown .whatsapp-quick-trigger:hover i,
.order-actions-dropdown .whatsapp-quick-trigger:focus-visible i {
    color: #159447;
}

.order-actions-dropdown form {
    margin: 0;
}

.order-actions-item-danger {
    color: #b8426d;
}

.order-actions-item-danger i {
    color: #b8426d;
}

.order-actions-item-danger:hover {
    background: rgba(184, 66, 109, 0.08);
}

.history-table .status-cell .status-chip,
.history-table .amount-cell .amount-pill {
    vertical-align: middle;
}

.amount-pill {
    min-width: 78px;
    font-size: 13px;
}

.amount-pill.pending {
    background: #fef3c7;
    color: #7c2d12;
}

.amount-pill.paid {
    background: #dcfce7;
    color: #14532d;
}

.history-filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
    align-items: end;
}

.modal-filters-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(180px, 1fr));
    gap: 14px;
    align-items: end;
    margin-bottom: 16px;
    grid-auto-flow: column;
}

.modal-filters-grid .filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.modal-filters-grid label {
    font-size: 12px;
    font-weight: 600;
    opacity: 0.75;
}

.filter-actions {
    display: flex;
    align-items: end;
}

.filter-actions .btn {
    height: 48px;
    width: 100%;
}

.search-history-modal-body {
    padding-bottom: 20px;
}

.search-history-modal-content .history-filters {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px 18px;
    margin-bottom: 20px;
    grid-auto-flow: row;
}

.search-history-modal-content .search-history-filter,
.search-history-modal-content .search-history-filter-search {
    min-width: 0;
}

.search-history-modal-content .search-history-filter-actions {
    width: 100%;
    justify-content: flex-end;
    align-items: end;
}

.search-history-modal-content .search-history-filter-actions .btn,
.client-orders-history-modal .history-filter-clear,
.client-orders-history-modal [data-history-clear] {
    width: 100%;
    min-width: 0;
    min-height: 50px;
    height: 50px;
    align-self: end;
}

.search-history-table-wrapper {
    overflow-x: auto;
}

.search-history-table-wrapper .history-table {
    table-layout: auto;
    min-width: 1280px;
}

.search-history-table-wrapper .history-table th,
.search-history-table-wrapper .history-table td {
    padding: 14px 14px;
}

.search-history-table-wrapper .history-table th:nth-child(2),
.search-history-table-wrapper .history-table td:nth-child(2),
.search-history-table-wrapper .history-table th:nth-child(5),
.search-history-table-wrapper .history-table td:nth-child(5),
.search-history-table-wrapper .history-table th:nth-child(6),
.search-history-table-wrapper .history-table td:nth-child(6),
.search-history-table-wrapper .history-table th:nth-child(7),
.search-history-table-wrapper .history-table td:nth-child(7),
.search-history-table-wrapper .history-table th:nth-child(8),
.search-history-table-wrapper .history-table td:nth-child(8) {
    white-space: nowrap;
}

.search-history-table-wrapper .history-table th:nth-child(2),
.search-history-table-wrapper .history-table td:nth-child(2) {
    min-width: 180px;
}

.search-history-table-wrapper .history-table th:nth-child(5),
.search-history-table-wrapper .history-table td:nth-child(5),
.search-history-table-wrapper .history-table th:nth-child(6),
.search-history-table-wrapper .history-table td:nth-child(6) {
    min-width: 150px;
}

.search-history-table-wrapper .history-table th:nth-child(7),
.search-history-table-wrapper .history-table td:nth-child(7),
.search-history-table-wrapper .history-table th:nth-child(8),
.search-history-table-wrapper .history-table td:nth-child(8) {
    min-width: 150px;
}

.search-history-table-wrapper .history-table th:nth-child(9),
.search-history-table-wrapper .history-table td:nth-child(9) {
    min-width: 120px;
}

.dashboard-delayed-filters {
    grid-template-columns: repeat(10, minmax(0, 1fr));
    gap: 14px 16px;
    align-items: end;
}

.dashboard-delayed-filter-search {
    grid-column: 1 / span 6;
}

.dashboard-delayed-filter-laundry {
    grid-column: 7 / span 4;
}

.dashboard-delayed-filter-start {
    grid-column: 1 / span 3;
}

.dashboard-delayed-filter-end {
    grid-column: 4 / span 3;
}

.dashboard-delayed-filter-sort {
    grid-column: 7 / span 2;
    min-width: 0;
}

.dashboard-delayed-filter-actions {
    grid-column: 9 / span 2;
    display: flex;
    align-items: end;
}

.dashboard-delayed-filter-actions .btn {
    width: 100%;
    min-width: 0;
}

.dashboard-delayed-filter-sort select {
    min-width: 0;
    width: 100%;
    padding-right: 2.5rem;
}

.dashboard-delayed-detail-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0.85rem 1.4rem;
    border-radius: 16px;
    border: 1px solid var(--primary-dark);
    background: var(--primary-dark);
    color: #fff;
    font-weight: 700;
    box-shadow: 0 16px 32px rgba(71, 86, 158, 0.18);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.dashboard-delayed-detail-btn:hover,
.dashboard-delayed-detail-btn:focus-visible {
    background: #43509a;
    border-color: #43509a;
    color: #fff;
    box-shadow: 0 18px 34px rgba(67, 80, 154, 0.22);
    transform: translateY(-1px);
}

.dashboard-delayed-detail-btn:active {
    transform: translateY(0);
    box-shadow: 0 10px 22px rgba(67, 80, 154, 0.18);
}

@media (min-width: 1025px) {
    #reportDelayedOrdersModal .orders-card-list,
    #reportDelayedOrdersModal .pending-orders-mobile-results {
        display: none !important;
    }
}

@media (max-width: 1024px) {
    #reportDelayedOrdersModal .modal-dialog.modal-content.delayed-orders-modal.orders-modal-standard {
        width: min(980px, 94vw) !important;
        max-width: min(980px, 94vw) !important;
        max-height: calc(100vh - 36px) !important;
        border-radius: 24px !important;
    }

    #reportDelayedOrdersModal .modal-header {
        position: relative;
        min-height: 68px !important;
        padding: 16px 20px !important;
        justify-content: center !important;
    }

    #reportDelayedOrdersModal .modal-header h3 {
        width: 100%;
        margin: 0;
        text-align: center;
        font-size: 22px !important;
        line-height: 1.12 !important;
        font-weight: 700 !important;
        color: #304A9A !important;
    }

    #reportDelayedOrdersModal .modal-close-btn {
        position: absolute;
        top: 13px;
        right: 16px;
        width: 42px !important;
        height: 42px !important;
        min-width: 42px !important;
        min-height: 42px !important;
    }

    #reportDelayedOrdersModal .delayed-orders-modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch;
        padding: 16px 18px 20px !important;
        display: block !important;
    }

    #reportDelayedOrdersModal .dashboard-delayed-filters {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 14px;
        margin-bottom: 16px !important;
        align-items: end;
    }

    #reportDelayedOrdersModal .dashboard-delayed-filter-search { order: 1; }
    #reportDelayedOrdersModal .dashboard-delayed-filter-laundry { order: 2; }
    #reportDelayedOrdersModal .dashboard-delayed-filter-sort { order: 3; }
    #reportDelayedOrdersModal .dashboard-delayed-filter-start { order: 4; }
    #reportDelayedOrdersModal .dashboard-delayed-filter-end { order: 5; }
    #reportDelayedOrdersModal .dashboard-delayed-filter-actions { order: 6; }

    #reportDelayedOrdersModal label {
        display: block;
        margin-bottom: 6px;
        font-size: 11px;
        line-height: 1.1;
        font-weight: 700;
        color: #8B82A0;
    }

    #reportDelayedOrdersModal input,
    #reportDelayedOrdersModal select {
        width: 100%;
        min-height: 46px;
        border-radius: 14px;
        font-size: 14px;
        padding: 10px 12px;
        box-sizing: border-box;
    }

    #reportDelayedOrdersModal .dashboard-delayed-filter-actions .btn {
        width: 100%;
        min-height: 46px;
    }

    #reportDelayedOrdersModal .orders-table-desktop,
    #reportDelayedOrdersModal table,
    #reportDelayedOrdersModal .history-table,
    #reportDelayedOrdersModal .delayed-orders-table-shell {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        flex: 0 0 0 !important;
    }

    #reportDelayedOrdersModal .pending-orders-mobile-results {
        display: flex !important;
        flex-direction: column !important;
        gap: 14px !important;
        width: 100% !important;
        min-height: 0 !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 0 8px !important;
        overflow: visible !important;
    }

    #reportDelayedOrdersModal .pending-orders-mobile-results[style] {
        display: flex !important;
    }

    #reportDelayedOrdersModal .history-empty-state {
        margin-top: 6px;
    }
}

@media (max-width: 767px) {
    #reportDelayedOrdersModal .dashboard-delayed-filters {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    #reportDelayedOrdersModal .modal-dialog.modal-content.delayed-orders-modal.orders-modal-standard {
        width: min(96vw, 640px) !important;
        max-width: min(96vw, 640px) !important;
    }
}

.form-group-full {
    grid-column: 1 / -1;
}

.history-filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.history-filter-group label {
    font-size: 12px;
    font-weight: 600;
    opacity: 0.75;
}

.history-empty-state {
    display: none;
    padding: 18px;
    text-align: center;
    opacity: 0.7;
}

.orders-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 10px;
}

.orders-header-left {
    max-width: 60%;
}

.orders-header-right {
    display: flex;
    align-items: center;
}

.orders-inline-filters,
.orders-inline-filter-form {
    display: flex;
    align-items: flex-end;
    gap: 12px;
}

.orders-quick-toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.orders-quick-toggle-btn {
    min-height: 42px;
    padding: 0.68rem 1.1rem;
    border-radius: 14px;
    border: 1px solid rgba(191, 214, 238, 0.95);
    background: #ffffff;
    color: #4a5899;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(74, 88, 153, 0.08);
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.orders-quick-toggle-btn:hover,
.orders-quick-toggle-btn:focus-visible {
    background: rgba(237, 242, 255, 0.92);
    border-color: rgba(109, 136, 220, 0.85);
    color: #3f4f98;
    box-shadow: 0 10px 22px rgba(74, 88, 153, 0.14);
}

.orders-quick-toggle-btn.is-active {
    background: #fff5cf;
    border-color: rgba(244, 213, 105, 0.9);
    color: #9a6700;
    box-shadow: 0 10px 22px rgba(194, 153, 44, 0.16);
}

.orders-quick-toggle-count {
    min-width: 24px;
    min-height: 24px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    color: inherit;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}

.orders-quick-toggle-btn:not(.is-active) .orders-quick-toggle-count {
    background: rgba(233, 240, 255, 0.92);
    color: #4a5899;
}

.orders-pending-today-empty-state {
    margin-top: 16px;
}

.orders-total-filters {
    margin-bottom: 16px;
}

.filter-group-inline {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.filter-group-inline label {
    font-size: 11px;
    font-weight: 600;
    opacity: 0.7;
}

.filter-group-inline select {
    min-width: 150px;
}

.orders-filters-bar,
.orders-filters-center {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 14px;
    margin: 12px 0 18px;
    flex-wrap: wrap;
}

.third-party-filters-grid {
    margin-bottom: 18px;
}

.third-parties-table .actions-cell {
    flex-wrap: wrap;
}

.third-party-page {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.third-party-form-card,
.third-party-list-card {
    width: 100%;
    padding: 24px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(180, 207, 221, 0.55);
    box-shadow: 0 18px 40px rgba(74, 88, 153, 0.08);
}

.third-party-form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    gap: 18px 20px;
    align-items: end;
    width: 100%;
}

.third-party-form-grid .full-width {
    grid-column: 1 / -1;
}

.third-party-form-actions {
    margin-top: 0;
}

.third-party-metrics-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 18px;
    width: 100%;
    align-items: stretch;
}

.third-party-metrics-grid > .metric-card {
    grid-column: span 3;
}

.third-party-metrics-grid > .metric-card:nth-child(5) {
    grid-column: 2 / span 3;
}

.third-party-metrics-grid > .metric-card:nth-child(6) {
    grid-column: 5 / span 3;
}

.third-party-metrics-grid > .metric-card:nth-child(7) {
    grid-column: 8 / span 3;
}

.metric-card {
    min-height: 120px;
    padding: 22px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(180, 207, 221, 0.55);
    box-shadow: 0 18px 40px rgba(74, 88, 153, 0.08);
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.35rem;
}

.metric-card span {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    opacity: 0.75;
    margin-bottom: 10px;
}

.metric-card strong {
    font-size: 28px;
    font-weight: 700;
    color: #4A5899;
    line-height: 1;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.metric-card.metric-card-primary {
    background: rgba(231, 233, 248, 0.72);
    border-color: rgba(74, 88, 153, 0.18);
}

.metric-card.metric-card-primary strong {
    color: #4A5899;
}

.metric-card.metric-card-warning {
    background: rgba(254, 243, 199, 0.72);
    border-color: rgba(245, 158, 11, 0.22);
}

.metric-card.metric-card-warning strong {
    color: #92400e;
}

.metric-card.metric-card-danger {
    background: rgba(254, 226, 226, 0.72);
    border-color: rgba(220, 38, 38, 0.18);
}

.metric-card.metric-card-danger strong {
    color: #b91c1c;
}

.third-party-alert-action {
    color: #991b1b;
    background: rgba(254, 226, 226, 0.72);
}

.third-party-alert-action:hover {
    background: rgba(254, 202, 202, 0.88);
}

.metric-card.metric-card-success {
    background: rgba(220, 252, 231, 0.72);
    border-color: rgba(22, 163, 74, 0.18);
}

.metric-card.metric-card-success strong {
    color: #166534;
}

.third-party-filters {
    display: grid;
    grid-template-columns: repeat(6, minmax(160px, 1fr));
    gap: 14px;
    align-items: end;
    margin-bottom: 16px;
    margin-top: 16px;
}

.orders-filter-group,
.filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
}

.orders-filters-bar label,
.orders-filters-center label {
    font-size: 12px;
    font-weight: 600;
    opacity: 0.7;
}

.orders-filters-bar select,
.orders-filters-bar .form-select,
.orders-filters-center select {
    min-width: 180px;
    max-width: 200px;
}

.orders-filters-bar .btn,
.orders-filters-center .filter-btn {
    height: 42px;
    padding: 0 20px;
    min-width: auto;
}

.loyalty-chip.nuevo {
    background: #e8f0ff;
    color: #3152a0;
}

.loyalty-chip.ocasional {
    background: #f2e8fb;
    color: #7a3fa0;
}

.loyalty-chip.mensual {
    background: #ddf4f8;
    color: #22606d;
}

.loyalty-chip.habitual {
    background: #e7f8ee;
    color: #1f6a43;
}

.loyalty-chip.frecuente {
    background: #fff4d8;
    color: #92400e;
}

.loyalty-chip.inactivo {
    background: #eef1f5;
    color: #5b6472;
}

.loyalty-chip.sin-pedidos {
    background: #f3f4f6;
    color: #6b7280;
}

.closure-actions {
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.kpi-card {
    overflow: hidden;
    min-width: 0;
}

.kpi-money {
    display: flex;
    align-items: baseline;
    gap: 6px;
    white-space: nowrap;
    min-width: 0;
    max-width: 100%;
    overflow: visible;
}

.kpi-currency {
    font-size: clamp(18px, 2vw, 28px);
    font-weight: 500;
    line-height: 1;
    color: var(--primary);
    flex: 0 0 auto;
}

.kpi-value {
    font-size: clamp(26px, 2.4vw, 42px);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.5px;
    color: var(--primary);
    min-width: 0;
}

.kpi-number,
.kpi-percent {
    white-space: nowrap;
    max-width: 100%;
    min-width: 0;
    overflow: visible;
    font-size: clamp(26px, 2.4vw, 42px);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.5px;
    color: var(--primary);
}

.kpi-money.is-long .kpi-value,
.kpi-number.is-long,
.kpi-percent.is-long {
    font-size: clamp(24px, 2vw, 36px);
}

.kpi-money.is-very-long .kpi-value,
.kpi-number.is-very-long,
.kpi-percent.is-very-long {
    font-size: clamp(20px, 1.7vw, 30px);
}

.kpi-money.is-long .kpi-currency {
    font-size: clamp(16px, 1.6vw, 24px);
}

.quick-link-card {
    display: grid;
    gap: 0.85rem;
    align-content: start;
    min-height: 100%;
    color: var(--text);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.quick-link-card:hover {
    transform: translateY(-2px);
    border-color: rgba(74, 88, 153, 0.3);
    box-shadow: 0 20px 34px rgba(74, 88, 153, 0.16);
}

.quick-link-icon {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: rgba(74, 88, 153, 0.12);
    font-size: 1.45rem;
}

.quick-link-title {
    margin: 0;
    color: var(--primary);
    font-size: 1.08rem;
}

.quick-link-text {
    margin: 0;
    color: var(--muted);
}

.client-card {
    display: flex;
    flex-direction: column;
}

.client-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.client-edit-btn {
    flex-shrink: 0;
}

.client-card-actions {
    margin-top: auto;
    padding-top: 16px;
}

.admin-actions-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.dashboard-info-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: stretch;
}

.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 340px);
    gap: 1.5rem;
    align-items: stretch;
}

.dashboard-hero-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.dashboard-user-card {
    display: flex;
    align-items: center;
    padding: 0.95rem 1.2rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(85, 156, 173, 0.2);
}

.dashboard-user-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.dashboard-user-meta strong {
    color: var(--primary);
    font-size: 0.98rem;
}

.dashboard-user-meta .divider {
    width: 1px;
    height: 16px;
    background-color: rgba(0, 0, 0, 0.2);
    flex: 0 0 1px;
}

.info-chip {
    min-width: 160px;
    padding: 0.95rem 1rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(85, 156, 173, 0.2);
    display: grid;
    gap: 0.25rem;
}

.info-chip-label {
    color: var(--muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 700;
}

.auth-card {
    width: min(100%, 430px);
}

.card h2,
.card h3 {
    margin-top: 0;
    color: var(--primary);
}

.card p {
    line-height: 1.55;
}

.form {
    display: grid;
    gap: 1rem;
    width: 100%;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.125rem 1.25rem;
    align-items: start;
}

.order-form-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(180px, 1fr));
    gap: 18px 20px;
    align-items: end;
    width: 100%;
}

@media (max-width: 1200px) {
    .order-form-grid {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }

    .order-amounts-row {
        grid-template-columns: repeat(3, minmax(160px, 1fr));
    }
}

@media (max-width: 1100px) {
    .legacy-resolution-grid {
        grid-template-columns: 1fr;
    }

    .legacy-service-selector-grid {
        grid-template-columns: 1fr;
    }

    .third-party-form-grid,
    .third-party-filters {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }

    .third-party-metrics-grid {
        grid-template-columns: repeat(2, minmax(180px, 1fr));
    }

    .third-party-metrics-grid > .metric-card,
    .third-party-metrics-grid > .metric-card:nth-child(5),
    .third-party-metrics-grid > .metric-card:nth-child(6),
    .third-party-metrics-grid > .metric-card:nth-child(7) {
        grid-column: auto;
    }
}

@media (max-width: 640px) {
    .legacy-resolution-card {
        padding: 16px;
    }

    .header-orden-antigua {
        flex-direction: column;
        align-items: flex-start;
    }

    .header-orden-antigua .btn {
        align-self: flex-end;
    }

    .legacy-order-banner,
    .banner-orden-antigua {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .rectification-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .rectification-header .btn {
        align-self: flex-end;
    }

    .rectification-banner,
    .rectification-order-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .rectification-inline-search,
    .rectification-linked-order-row,
    .rectification-client-search,
    .rectification-client-grid,
    .rectification-form-grid,
    .rectification-finance-grid,
    .rectification-service-option-grid,
    .rectification-service-option-fields {
        grid-template-columns: 1fr;
    }

    .rectification-order-card-head,
    .rectification-order-card-body {
        align-items: stretch;
        flex-direction: column;
    }

    .rectification-order-card-body .btn {
        width: 100%;
    }

    .order-form-grid {
        grid-template-columns: 1fr;
    }

    .order-amounts-row {
        grid-template-columns: 1fr;
    }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    min-width: 0;
}

.form-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
    padding-top: 0.125rem;
}

label {
    font-weight: 700;
    color: var(--text);
    padding-top: 16px;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid rgba(85, 156, 173, 0.55);
    border-radius: 14px;
    padding: 0.85rem 0.95rem;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.94);
    color: var(--text);
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
    margin-top: 4px;
}

select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;

    padding-right: 2.75rem;

    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 20 20' fill='none'%3E%3Cpath d='M5 7.5L10 12.5L15 7.5' stroke='%232f3f8f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    background-size: 14px;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--color-focus-ring);
}

input[readonly] {
    background: rgba(255, 255, 255, 0.55);
    color: var(--muted);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-width: 150px;
    min-height: 46px;
    border: none;
    border-radius: var(--radius-sm);
    padding: 0.85rem 1.1rem;
    background: var(--color-button-primary);
    color: var(--white);
    font-size: 0.98rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: var(--shadow-button);
    transition: transform 0.18s ease, background 0.18s ease;
}

.btn:hover {
    background: var(--color-button-primary-hover);
    transform: translateY(-1px);
}

.btn i,
.btn .fa,
.btn .fas,
.btn .far,
.btn .fa-solid,
.btn .btn-icon,
.btn .button-icon,
.btn .icon,
.btn .btn-action-icon {
    color: currentColor;
}

.btn .btn-icon,
.btn .button-icon,
.btn .icon,
.btn .btn-action-icon,
.btn .icon-circle,
.btn .btn-icon-circle {
    color: currentColor;
    border-color: currentColor;
}

body.has-custom-theme-overrides .btn .icon-circle,
body.has-custom-theme-overrides .btn .btn-icon-circle {
    background: color-mix(in srgb, currentColor 10%, transparent);
}

body.has-custom-theme-overrides .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.order-detail-header-void-btn) .icon-circle,
body.has-custom-theme-overrides .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.order-detail-header-void-btn) .btn-icon-circle {
    background: rgba(255, 255, 255, 0.16);
}

body.has-custom-theme-overrides .btn.btn-secondary .icon-circle,
body.has-custom-theme-overrides .btn.btn-secondary .btn-icon-circle {
    background: color-mix(in srgb, currentColor 12%, transparent);
}

.btn-secondary {
    background: var(--color-button-secondary);
    box-shadow: var(--shadow-button);
}

.btn-secondary:hover {
    background: var(--color-button-secondary-hover);
}

.btn-danger {
    background: #b8426d;
    box-shadow: 0 14px 26px rgba(184, 66, 109, 0.22);
}

.btn-danger:hover {
    background: #9e345d;
}

.btn-ghost {
    background: rgba(255, 255, 255, 0.75);
    color: var(--primary);
    border: 1px solid var(--color-button-outline-border);
    box-shadow: none;
    gap: 8px;
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.95);
}

.btn:disabled {
    background: #b7b0c3;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.order-form-toolbar,
.order-admin-tools {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    margin-top: 16px;
}

.order-form-toolbar {
    margin-bottom: 0;
}

.order-form-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.receipt-code-label-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.expected-order-code-trigger {
    background: transparent;
    border: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
}

.expected-order-code-trigger:hover,
.expected-order-code-trigger:focus-visible {
    color: var(--primary-dark);
    opacity: 1;
    outline: none;
}

.expected-order-code-action,
.expected-order-code-chip,
.expected-order-code-chip--legacy,
.expected-order-code-feedback {
    display: none;
}

.btn-secondary-action-outline {
    background: var(--color-button-tertiary-bg, var(--color-button-outline-bg));
    color: var(--color-button-tertiary-text, var(--primary));
    border: 1px solid var(--color-button-tertiary-border, var(--color-button-outline-border));
    box-shadow: none;
}

.btn-secondary-action-outline:hover {
    background: var(--color-button-tertiary-hover, var(--color-button-outline-hover-bg));
    color: var(--color-button-tertiary-text, var(--primary-dark));
}

.whatsapp-quick-trigger,
.order-detail-whatsapp-link,
.search-whatsapp-action,
.orders-whatsapp-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #ffffff;
    color: #188b4c;
    border: 1px solid rgba(37, 211, 102, 0.28);
    box-shadow: 0 6px 16px rgba(23, 122, 67, 0.06);
}

.whatsapp-quick-trigger:hover,
.whatsapp-quick-trigger:focus-visible,
.order-detail-whatsapp-link:hover,
.order-detail-whatsapp-link:focus-visible,
.search-whatsapp-action:hover,
.search-whatsapp-action:focus-visible,
.orders-whatsapp-action-btn:hover,
.orders-whatsapp-action-btn:focus-visible {
    background: rgba(37, 211, 102, 0.08);
    color: #12733c;
    border-color: rgba(23, 139, 76, 0.44);
    box-shadow: 0 10px 20px rgba(23, 122, 67, 0.10);
    transform: translateY(-1px);
}

.whatsapp-quick-trigger:active,
.order-detail-whatsapp-link:active,
.search-whatsapp-action:active,
.orders-whatsapp-action-btn:active {
    background: rgba(37, 211, 102, 0.12);
    color: #12733c;
    border-color: rgba(23, 139, 76, 0.5);
    box-shadow: 0 4px 10px rgba(23, 122, 67, 0.08);
    transform: translateY(0);
}

.whatsapp-quick-trigger:focus-visible,
.order-detail-whatsapp-link:focus-visible,
.search-whatsapp-action:focus-visible,
.orders-whatsapp-action-btn:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px rgba(37, 211, 102, 0.16),
        0 10px 20px rgba(23, 122, 67, 0.10);
}

.orders-whatsapp-action-btn {
    min-height: 40px;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 700;
}

.secondary-top-action-btn {
    background: var(--color-button-tertiary-bg, var(--color-button-outline-bg));
    color: var(--color-button-tertiary-text, var(--primary));
    border: 1px solid var(--color-button-tertiary-border, var(--color-button-outline-border));
    border-radius: 14px;
    font-weight: 700;
    box-shadow: var(--shadow-soft);
}

.secondary-top-action-btn:hover,
.secondary-top-action-btn:focus-visible {
    background: var(--color-button-tertiary-hover, var(--color-button-outline-hover-bg));
    color: var(--color-button-tertiary-text, var(--primary-dark));
    border-color: var(--color-button-tertiary-border, var(--color-button-outline-border));
    box-shadow: var(--shadow-soft);
    transform: none;
}

.secondary-top-action-btn:active {
    background: var(--color-button-tertiary-hover, var(--color-button-outline-hover-bg));
    color: var(--color-button-tertiary-text, var(--primary-dark));
    border-color: var(--color-button-tertiary-border, var(--color-button-outline-border));
    box-shadow: var(--shadow-soft);
    transform: none;
}

.secondary-top-action-btn:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px var(--color-focus-ring),
        var(--shadow-soft);
}

.orders-secondary-action-btn {
    background: var(--color-button-tertiary-bg, var(--color-button-outline-bg));
    color: var(--color-button-tertiary-text, var(--primary));
    border: 1px solid var(--color-button-tertiary-border, var(--color-button-outline-border));
    box-shadow: var(--shadow-soft);
}

.orders-secondary-action-btn:hover,
.orders-secondary-action-btn:focus-visible {
    background: var(--color-button-tertiary-hover, var(--color-button-outline-hover-bg));
    color: var(--color-button-tertiary-text, var(--primary-dark));
    border-color: var(--color-button-tertiary-border, var(--color-button-outline-border));
    box-shadow: var(--shadow-soft);
}

.orders-secondary-action-btn:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px var(--color-focus-ring),
        var(--shadow-soft);
}

.orders-detail-action-btn {
    background: var(--primary);
    color: #ffffff;
    border: 1px solid var(--primary);
    box-shadow: var(--shadow-button-primary-strong);
}

.orders-detail-action-btn:hover,
.orders-detail-action-btn:focus-visible {
    background: var(--primary-dark);
    color: #ffffff;
    border-color: var(--primary-dark);
    box-shadow: var(--shadow-button-primary-hover);
    transform: translateY(-1px);
}

.orders-detail-action-btn:focus-visible {
    outline: none;
    box-shadow:
        0 0 0 3px var(--color-focus-ring),
        var(--shadow-button-primary-hover);
}

.btn-secondary-action-ghost {
    background: var(--color-button-tertiary-bg, transparent);
    color: var(--color-button-tertiary-text, rgba(47, 36, 64, 0.82));
    border: 1px solid var(--color-button-tertiary-border, transparent);
    box-shadow: none;
}

.btn-secondary-action-ghost:hover {
    background: var(--color-button-tertiary-hover, rgba(47, 36, 64, 0.06));
    color: var(--color-button-tertiary-text, var(--text));
}

body.has-custom-theme-overrides,
.appearance-page-shell,
.appearance-modal,
.appearance-live-preview {
    --color-button-outline-bg: var(--color-button-tertiary-bg);
    --color-button-outline-border: var(--color-button-tertiary-border);
    --color-button-outline-hover-bg: var(--color-button-tertiary-hover);
}

body.has-custom-theme-overrides .btn-secondary-action-outline:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn),
body.has-custom-theme-overrides .secondary-top-action-btn:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn),
body.has-custom-theme-overrides .orders-secondary-action-btn,
body.has-custom-theme-overrides .mobile-view-all-button,
body.has-custom-theme-overrides .btn-outline-primary,
body.has-custom-theme-overrides .btn-secondary-action-ghost,
body.has-custom-theme-overrides .btn-secondary-action {
    color: var(--color-button-tertiary-text, var(--color-primary));
    border-color: var(--color-button-tertiary-border, var(--color-button-outline-border));
    background: var(--color-button-tertiary-bg, #ffffff);
    border-radius: var(--button-radius, var(--radius-sm));
    padding: var(--button-padding-y, 13px) var(--button-padding-x, 24px);
    font-size: var(--button-font-size, 0.95rem);
}

body.has-custom-theme-overrides .btn-secondary-action-outline:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn):hover,
body.has-custom-theme-overrides .btn-secondary-action-outline:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn):focus-visible,
body.has-custom-theme-overrides .secondary-top-action-btn:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn):hover,
body.has-custom-theme-overrides .secondary-top-action-btn:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn):focus-visible,
body.has-custom-theme-overrides .orders-secondary-action-btn:hover,
body.has-custom-theme-overrides .orders-secondary-action-btn:focus-visible,
body.has-custom-theme-overrides .mobile-view-all-button:hover,
body.has-custom-theme-overrides .mobile-view-all-button:focus-visible,
body.has-custom-theme-overrides .btn-outline-primary:hover,
body.has-custom-theme-overrides .btn-outline-primary:focus-visible,
body.has-custom-theme-overrides .btn-secondary-action-ghost:hover,
body.has-custom-theme-overrides .btn-secondary-action-ghost:focus-visible,
body.has-custom-theme-overrides .btn-secondary-action:hover,
body.has-custom-theme-overrides .btn-secondary-action:focus-visible {
    background: var(--color-button-tertiary-hover, var(--color-surface-soft));
    color: var(--color-button-tertiary-text, var(--color-primary));
    border-color: var(--color-button-tertiary-border, var(--color-primary));
}

body.has-custom-theme-overrides .btn-secondary-action-outline i,
body.has-custom-theme-overrides .secondary-top-action-btn i,
body.has-custom-theme-overrides .orders-secondary-action-btn i,
body.has-custom-theme-overrides .mobile-view-all-button i,
body.has-custom-theme-overrides .btn-outline-primary i,
body.has-custom-theme-overrides .btn-secondary-action-ghost i,
body.has-custom-theme-overrides .btn-secondary-action i {
    color: currentColor;
}

.actions-dropdown {
    position: relative;
    flex-shrink: 0;
}

.actions-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 40px;
    padding: 9px 14px;
}

.actions-dropdown-toggle i {
    font-size: 12px;
    transition: transform 0.18s ease;
}

.actions-dropdown.is-open .actions-dropdown-toggle i {
    transform: rotate(180deg);
}

.actions-dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 280px;
    padding: 8px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(85, 156, 173, 0.18);
    box-shadow: 0 18px 34px rgba(47, 36, 64, 0.12);
    display: none;
    z-index: 50;
}

.actions-dropdown.is-open .actions-dropdown-menu {
    display: grid;
    gap: 4px;
}

.actions-dropdown-item {
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--text);
    text-decoration: none;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    text-align: left;
    cursor: pointer;
}

.actions-dropdown-item:hover {
    background: rgba(47, 36, 64, 0.05);
}

.actions-dropdown-item:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.actions-dropdown-item-icon {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.actions-dropdown-item-copy {
    display: grid;
    gap: 3px;
}

.actions-dropdown-item-copy strong {
    color: var(--primary);
    font-size: 14px;
    line-height: 1.2;
}

.actions-dropdown-item-copy small {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
}

.client-search-group {
    position: relative;
}

.client-search-shell {
    position: relative;
}

.client-search-results {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 40;
    max-height: 320px;
    overflow-y: auto;
    background: #ffffff;
    border: 1px solid #d8e7ef;
    border-radius: 16px;
    box-shadow: 0 18px 36px rgba(55, 48, 90, 0.12);
    padding: 8px;
}

.client-search-results[hidden] {
    display: none;
}

.client-search-result-item {
    width: 100%;
    border: 0;
    background: transparent;
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    text-align: left;
    cursor: pointer;
    color: #33427f;
}

.client-search-result-item:hover,
.client-search-result-item.is-active {
    background: #f9fafb;
}

.client-search-result-left {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    flex: 1;
}

.client-search-result-name {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    color: #25315d;
}

.client-search-result-name mark,
.client-search-result-dni mark {
    background: transparent;
    color: inherit;
    font-weight: 700;
}

.client-search-result-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0.82rem;
    color: #6b7280;
}

.client-search-result-phone {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.client-search-result-phone i {
    font-size: 11px;
    color: #8b97ab;
}

.client-search-frequency-chip {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
}

.client-search-frequency-chip.chip-low {
    background: #f3f0ff;
    color: #6b5aa6;
}

.client-search-frequency-chip.chip-medium {
    background: #fff6dc;
    color: #b7791f;
}

.client-search-frequency-chip.chip-high {
    background: #eaf8ef;
    color: #1f7a45;
}

.client-search-result-right {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.client-dni-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 96px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #f3f0ff;
    color: #44539a;
    font-weight: 700;
    font-size: 14px;
    line-height: 1;
    white-space: nowrap;
}

.client-search-result-item:hover .client-dni-pill,
.client-search-result-item.is-active .client-dni-pill,
.client-results-modal-item:hover .client-dni-pill {
    background: #e9e5ff;
}

.client-search-result-dni {
    letter-spacing: 0.01em;
}

.client-search-empty {
    padding: 12px 14px;
    color: #6e7b94;
    font-size: 0.9rem;
}

.client-search-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px 4px;
    border-top: 1px solid #edf1f6;
    margin-top: 6px;
}

.client-search-footer-copy {
    color: #6b7280;
    font-size: 0.78rem;
}

.client-search-footer-action {
    border: 0;
    background: transparent;
    color: #44539a;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    padding: 4px 6px;
    border-radius: 8px;
}

.client-search-footer-action:hover {
    background: #f7f5ff;
}

.client-results-modal-card {
    width: min(92vw, 760px);
    max-width: 760px;
}

.client-results-modal-body {
    max-height: 70vh;
    overflow: hidden;
}

.client-results-list {
    display: grid;
    gap: 10px;
    max-height: 60vh;
    overflow-y: auto;
}

.client-results-modal-empty {
    padding: 18px;
    border: 1px dashed #d8e7ef;
    border-radius: 14px;
    color: #6e7b94;
    text-align: center;
}

.client-results-modal-item {
    width: 100%;
    border: 1px solid #e5ebf2;
    background: #ffffff;
    border-radius: 16px;
    padding: 14px 16px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 14px;
    text-align: left;
}

.client-results-modal-item:hover {
    background: #f9fafb;
    border-color: #d7deea;
}

.client-results-modal-left {
    display: grid;
    gap: 5px;
    min-width: 0;
    flex: 1;
}

.client-results-modal-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.client-results-modal-name {
    color: #25315d;
    font-size: 0.96rem;
    font-weight: 700;
}

.client-results-modal-right {
    display: flex;
    align-items: center;
    justify-content: center;
}

.client-results-modal-dni {
    white-space: nowrap;
}

.client-results-modal-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    color: #6b7280;
    font-size: 0.84rem;
}

.client-results-modal-select {
    flex-shrink: 0;
    align-self: center;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.order-entry-card.is-locked {
    opacity: 0.92;
}

.order-entry-blocked-copy {
    margin: 0 0 16px;
    color: var(--muted);
    font-weight: 600;
}

.order-entry-fieldset {
    margin: 0;
    padding: 0;
    border: 0;
    min-width: 0;
}

.order-entry-fieldset:disabled {
    opacity: 0.62;
    pointer-events: none;
}

.order-services-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.field-label-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.field-help-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    color: var(--primary);
    cursor: help;
    opacity: 0.78;
}

.field-help-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 50%;
    bottom: calc(100% + 10px);
    transform: translateX(-50%);
    min-width: 220px;
    max-width: 260px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(47, 36, 64, 0.78);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    white-space: pre-line;
    box-shadow: 0 18px 28px rgba(47, 36, 64, 0.18);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.16s ease, transform 0.16s ease;
    z-index: 20;
}

.field-help-tooltip:hover::after,
.field-help-tooltip:focus-visible::after {
    opacity: 1;
    transform: translateX(-50%) translateY(-2px);
}

.client-register-subtitle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.client-register-tooltip {
    flex: 0 0 auto;
    color: rgba(74, 91, 168, 0.78);
}

.client-register-tooltip i {
    font-size: 0.88rem;
}

.order-services-card {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.56);
    border: 1px solid rgba(85, 156, 173, 0.16);
    margin-bottom: 16px;
    margin-top: 16px;
}

.order-services-card-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.info-item-service-detail .info-item-service-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
}

.info-item-service-detail .info-item-service-name {
    min-width: 0;
    margin: 0;
}

.service-inline-view-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: none;
    background: transparent;
    color: rgba(74, 88, 153, 0.72);
    cursor: pointer;
    transition: color 0.18s ease, transform 0.18s ease;
    flex: 0 0 auto;
}

.service-inline-view-btn:hover,
.service-inline-view-btn:focus-visible {
    color: var(--primary);
    transform: scale(1.04);
}

.service-inline-view-btn i {
    font-size: 15px;
}

.order-services-table-shell {
    max-height: 260px;
}

.order-services-table td:last-child,
.order-services-table th:last-child {
    width: 120px;
}

.order-services-empty-row td {
    color: var(--muted);
}

.order-services-row-actions {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: nowrap;
}

.order-services-alert,
.order-overpay-alert,
.service-picker-error {
    color: #991b1b;
}

.order-amounts-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 18px 20px;
    align-items: start;
    margin-top: 18px;
}

.order-amounts-row .form-group {
    align-self: stretch;
}

.order-amounts-row .form-group input {
    min-height: 48px;
}

.order-operational-load-preview {
    --load-preview-accent: #4a5899;
    display: grid;
    gap: 5px;
    margin-top: 10px;
    padding: 11px 13px;
    border: 1px solid rgba(74, 88, 153, 0.18);
    border-radius: 12px;
    background: rgba(245, 247, 255, 0.86);
    color: #5d5668;
    font-size: 0.78rem;
    line-height: 1.35;
}

.order-operational-load-preview[hidden],
.order-operational-load-preview-suggestion[hidden],
.order-operational-load-preview-actions[hidden] {
    display: none;
}

.order-operational-load-preview.is-low { --load-preview-accent: #3c9564; }
.order-operational-load-preview.is-medium { --load-preview-accent: #a87917; }
.order-operational-load-preview.is-high { --load-preview-accent: #c06a37; }
.order-operational-load-preview.is-critical {
    --load-preview-accent: #b33f56;
    border-color: rgba(179, 63, 86, 0.28);
    background: rgba(255, 244, 247, 0.92);
}

.order-operational-load-preview-heading {
  display: grid;
  gap: 2px;
}

.order-operational-load-preview-heading strong {
  color: var(--load-preview-accent);
  font-size: 0.84rem;
}

.order-operational-load-preview-heading span {
  color: #514b60;
  font-weight: 700;
}

.order-operational-load-preview p,
.order-operational-load-preview-suggestion {
    margin: 0;
}

.order-operational-load-preview-suggestion,
.order-operational-load-preview-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.order-operational-load-preview-suggestion {
  color: var(--load-preview-accent);
  font-weight: 700;
}

.order-operational-load-preview-suggestion {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  margin-top: 6px;
  padding: 9px 10px;
  border: 1px solid rgba(60, 149, 100, 0.2);
  border-radius: 10px;
  background: rgba(235, 249, 240, 0.82);
  color: #357b56;
}

.order-operational-load-preview-suggestion > i {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: #3c9564;
}

.order-operational-load-preview-suggestion-copy {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.order-operational-load-preview-suggestion-copy small {
  color: #6f8c79;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.order-operational-load-preview-suggestion-copy strong {
  color: #2f7250;
  font-size: 0.9rem;
}

.order-operational-load-preview-suggestion-copy em {
  color: #5f806c;
  font-size: 0.74rem;
  font-style: normal;
  font-weight: 600;
}

.order-operational-load-preview .btn {
    min-height: 32px;
    padding: 6px 10px;
    font-size: 0.75rem;
}

@media (max-width: 767px) {
    .order-operational-load-preview-suggestion,
    .order-operational-load-preview-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .order-operational-load-preview .btn {
        width: 100%;
    }
}

.payment-rounding-row {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    width: 100%;
    min-height: 34px;
    margin-top: 12px;
}

.payment-rounding-toggle {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    cursor: pointer;
    user-select: none;
    transition: opacity 0.18s ease;
}

.payment-rounding-toggle.is-hidden {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.payment-rounding-toggle input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

.payment-rounding-toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    border-radius: 999px;
    background: rgba(180, 189, 220, 0.9);
    transition: background 0.2s ease;
}

.payment-rounding-toggle-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 4px 12px rgba(53, 64, 116, 0.18);
    transition: transform 0.2s ease;
}

.payment-rounding-toggle-copy {
    color: var(--primary);
    font-size: 0.95rem;
    font-weight: 600;
}

.payment-rounding-toggle input:checked + .payment-rounding-toggle-switch {
    background: rgba(85, 156, 173, 0.95);
}

.payment-rounding-toggle input:checked + .payment-rounding-toggle-switch::after {
    transform: translateX(20px);
}

@media (max-width: 768px) {
    .payment-rounding-row {
        justify-content: flex-start;
        margin-top: 10px;
    }
}

.service-picker-modal {
    width: min(1180px, 96vw);
    height: auto;
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
}

.service-picker-modal-body {
    padding: 0;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* The correction mode reuses the picker layout without adding a wrapper row. */
.service-picker-correction-form {
    display: contents;
}

.service-picker-reason-group {
    margin-top: 16px;
}

.service-picker-layout {
    display: grid;
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    gap: 0;
    height: 100%;
    min-height: 0;
}

.service-picker-sidebar {
    padding: 24px;
    border-right: 1px solid rgba(85, 156, 173, 0.16);
    background: rgba(248, 239, 246, 0.42);
    background-image: none !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: 0;
    align-self: stretch;
    overflow: hidden;
    padding-top: 20px;
    border-radius: 22px 0 0 22px;
}

.service-picker-list {
    display: grid;
    gap: 12px;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 8px 6px 12px 0;
    border-radius: 18px;
}

.service-picker-item {
    width: 100%;
    border: 1px solid rgba(85, 156, 173, 0.16);
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(252, 247, 251, 0.98) 100%);
    background-image: none !important;
    box-shadow: 0 10px 20px rgba(74, 88, 153, 0.06);
    padding: 15px 16px;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    position: relative;
}

.service-picker-item-icon {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: rgba(74, 88, 153, 0.08);
    background-image: none !important;
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.service-picker-item-copy {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.service-picker-item-copy strong {
    color: var(--primary);
    font-size: 15px;
}

.service-picker-item-copy span {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.35;
}

.service-picker-item:hover {
    border-color: rgba(85, 156, 173, 0.28);
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 14px 28px rgba(74, 88, 153, 0.1);
    transform: translateY(-1px);
}

.service-picker-item.is-active {
    border-color: var(--color-button-outline-border);
    background: color-mix(in srgb, var(--color-surface) 76%, white 24%);
    box-shadow: var(--shadow-soft);
    transform: translateY(-1px);
}

.service-picker-item.is-active .service-picker-item-icon {
    background: var(--color-button-outline-hover-bg);
    color: var(--primary);
}

.service-picker-detail {
    padding: 24px;
    display: grid;
    gap: 18px;
    align-content: start;
    min-height: 0;
    min-width: 0;
    overflow-y: auto;
}

.service-picker-detail-header {
    display: grid;
    gap: 6px;
}

.service-picker-heading {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.service-picker-icon {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    background: rgba(74, 88, 153, 0.1);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}

.service-picker-heading-copy {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.service-picker-heading-main {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.service-picker-kicker {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--secondary);
    letter-spacing: 0.05em;
}

.service-picker-detail-header h4 {
    margin: 0;
    color: var(--primary);
    font-size: 24px;
}

.service-picker-detail-header p {
    margin: 0;
    color: var(--muted);
}

.service-price-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(74, 88, 153, 0.1);
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
}

.service-picker-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 18px;
    align-items: start;
}

.service-picker-form-grid .form-group:not(.service-detail-group) input,
.service-picker-form-grid .form-group:not(.service-detail-group) select {
    min-height: 52px;
    height: 52px;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
    line-height: 1.2;
    border-radius: 16px;
}

.service-detail-group {
    grid-column: 1 / -1;
}

.service-price-group {
    gap: 8px;
}

.service-price-group label i {
    margin-left: 6px;
    font-size: 12px;
    opacity: 0.7;
}

.service-price-input-wrap {
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr);
    min-height: 52px;
    height: 52px;
    border: 1px solid rgba(85, 156, 173, 0.55);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.94);
    overflow: hidden;
    align-content: center;
}

.service-price-prefix {
    height: 52px;
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(74, 88, 153, 0.08);
    color: var(--primary);
    font-size: 16px;
    font-weight: 700;
}

.service-price-input-wrap input {
    border: none;
    border-radius: 0;
    height: 52px;
    min-height: 52px;
    padding: 0.85rem 1rem 0.85rem 0.75rem;
    line-height: 1.2;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    box-shadow: none;
}

#service-quantity-input {
    height: 52px;
    min-height: 52px;
}

#service-size-select {
    height: 52px;
    min-height: 52px;
}

.order-submit-actions {
    margin-top: 24px;
}

.service-price-input-wrap:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(74, 88, 153, 0.14);
}

.service-price-input-wrap input:focus {
    box-shadow: none;
}

.service-total-card {
    display: grid;
    gap: 4px;
    padding: 18px 20px;
    border-radius: 20px;
    background: rgba(231, 233, 248, 0.52);
    border: 1px solid rgba(74, 88, 153, 0.18);
}

.service-total-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--muted);
    letter-spacing: 0.05em;
}

.service-total-card strong {
    color: var(--primary);
    font-size: clamp(28px, 4vw, 38px);
    line-height: 1;
}

.service-summary-line {
    margin: 8px 0px 0px 16px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.45;
    padding-bottom: 16px;
}

.service-picker-actions {
    padding-top: 6px;
    justify-content: flex-end;
}

.service-compound-section {
    display: grid;
    gap: 12px;
    padding: 16px;
    border-radius: 18px;
    margin-bottom: 16px;
    margin-top: 16px;
    background: rgba(248, 239, 246, 0.38);
    border: 1px solid rgba(85, 156, 173, 0.16);
}

.service-compound-section[hidden],
#service-size-group[hidden] {
    display: none !important;
}

.service-compound-toolbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.service-compound-toolbar h5 {
    margin: 0 0 4px;
    color: var(--primary);
    font-size: 16px;
}

.service-compound-table-shell {
    max-height: 180px;
}

.service-compound-empty-row td {
    color: var(--muted);
}

.order-services-detail-meta {
    margin-bottom: 12px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.order-detail-modal-shell {
    width: min(1120px, 94vw);
}

.order-detail-modal-heading {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-detail-modal-shell .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.order-detail-section-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.order-detail-section-copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    min-width: 0;
    flex: 1;
}

.order-detail-section-copy-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    width: 100%;
}

.order-detail-section-copy .section-title,
.order-detail-section-copy .section-subtitle {
    margin: 0;
}

.btn-mark-ready-soft {
    background: #eaf8ef;
    color: #1f7a45;
    border: 1px solid #bde8cc;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    padding: 9px 14px;
    min-height: 40px;
    font-size: 0.92rem;
    font-weight: 700;
    box-shadow: none;
}

.btn-mark-ready-soft:hover {
    background: #ddf3e6;
    color: #1b6c3d;
    border-color: #b0dfc0;
}

.btn-mark-ready-soft i {
    font-size: 0.82rem;
    color: inherit;
}

.btn-mark-ready-soft:disabled {
    opacity: 0.7;
    cursor: wait;
}

.confirm-status-modal {
    padding: 1rem;
}

.confirm-status-modal .modal-dialog.modal-content.confirm-status-dialog {
    width: min(92vw, 480px) !important;
    max-width: 480px !important;
    height: auto !important;
    min-height: unset !important;
    max-height: none !important;
    margin: auto;
    display: block !important;
    overflow: hidden !important;
}

.confirm-status-modal .modal-header,
.order-ready-confirm-shell .modal-header {
    padding: 1rem 1.1rem 0;
    border-bottom: 0;
    align-items: flex-start;
}

.confirm-modal-header-copy h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--muted);
}

.confirm-status-modal .confirm-status-content,
.confirm-status-modal .confirm-status-body,
.confirm-modal-card,
.order-ready-confirm-body {
    height: auto !important;
    min-height: unset !important;
    flex: unset !important;
    overflow: visible !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 14px;
    padding: 0 28px 28px;
}

.confirm-modal-icon {
    width: 64px;
    height: 64px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eaf8ef;
    color: #1f7a45;
    font-size: 1.6rem;
    margin-top: 24px;
}

.order-ready-confirm-title {
    margin: 0;
    color: var(--primary);
    font-size: 1.35rem;
    line-height: 1.2;
    font-weight: 700;
}

.order-ready-confirm-copy {
    margin: 0;
    color: var(--muted);
    line-height: 1.55;
    max-width: 34ch;
}

.confirm-modal-actions,
.order-ready-confirm-actions,
.confirm-status-modal .confirm-status-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
    width: 100%;
}

.confirm-modal-actions .btn,
.order-ready-confirm-actions .btn {
    min-height: 40px;
    padding: 10px 14px;
}

.order-detail-modal-code {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.order-detail-subtitle,
.order-detail-modal-code {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.legacy-order-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: #FFF4E5;
    border: 1px solid #F3D7B6;
    color: #B7791F;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1;
    white-space: nowrap;
}

.order-voided-tag {
    background: #ececec;
    border: 1px solid #d5d5d5;
    color: #5f6368;
}

.order-regularized-tag {
    background: #eaf2ff;
    border: 1px solid #bfd4ff;
    color: #3156a3;
}

.order-detail-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.order-detail-search-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 14px;
    border: 1px solid rgba(180, 207, 221, 0.7);
    background: rgba(246, 248, 255, 0.9);
    color: var(--primary);
    box-shadow: none;
}

.order-detail-search-link:hover {
    background: rgba(232, 238, 255, 0.95);
    color: var(--primary-strong);
}

.whatsapp-quick-modal-shell {
    width: min(94vw, 560px);
    border-radius: 24px;
}

.whatsapp-quick-modal-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 2px 22px 18px;
}

.whatsapp-quick-options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.whatsapp-quick-option {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    flex: 1 1 calc(50% - 4px);
    min-width: 0;
    min-height: 42px;
    padding: 11px 42px 11px 14px;
    border-radius: 16px;
    border: 1px solid rgba(37, 211, 102, 0.22);
    background: #ffffff;
    color: #166f3b;
    font-size: 14px;
    font-weight: 700;
    text-align: left;
    box-shadow: 0 8px 18px rgba(23, 122, 67, 0.06);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.whatsapp-quick-option:hover,
.whatsapp-quick-option:focus-visible {
    background: rgba(37, 211, 102, 0.08);
    color: #12733c;
    border-color: rgba(23, 139, 76, 0.4);
    box-shadow: 0 12px 20px rgba(23, 122, 67, 0.09);
    outline: none;
}

.whatsapp-quick-option:active {
    background: rgba(37, 211, 102, 0.12);
    box-shadow: 0 6px 12px rgba(23, 122, 67, 0.07);
}

.whatsapp-quick-option.is-active {
    background: rgba(37, 211, 102, 0.12);
    color: #12733c;
    border-color: rgba(23, 139, 76, 0.44);
    box-shadow: 0 12px 20px rgba(23, 122, 67, 0.10);
}

.whatsapp-quick-option .whatsapp-template-check {
    display: none;
    flex: 0 0 auto;
    margin-left: auto;
    color: #159447;
    font-size: 13px;
}

.whatsapp-quick-option.is-active .whatsapp-template-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.whatsapp-quick-preview {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 0;
    padding-top: 12px;
    border-top: 1px solid rgba(194, 204, 232, 0.38);
}

.whatsapp-quick-preview-label {
    margin: 0;
    color: var(--primary-dark);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
}

.whatsapp-quick-preview-card {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(248, 250, 255, 0.96);
    border: 1px solid rgba(194, 204, 232, 0.48);
    color: var(--text-color);
    font-size: 14px;
    line-height: 1.65;
    white-space: pre-wrap;
    word-break: break-word;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.whatsapp-quick-preview-card.is-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    color: var(--muted);
    font-weight: 400;
    text-align: center;
}

.whatsapp-quick-preview-note {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.whatsapp-quick-preview-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 2px;
}

.whatsapp-quick-open-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 11px 16px;
    background: #1a7f43;
    color: #ffffff;
    border: 1px solid #1a7f43;
    box-shadow: 0 12px 22px rgba(26, 127, 67, 0.18);
}

.whatsapp-quick-open-btn:hover,
.whatsapp-quick-open-btn:focus-visible {
    background: #166d39;
    color: #ffffff;
    border-color: #166d39;
}

.whatsapp-quick-open-btn:disabled {
    background: #d4dbe8;
    color: #7c889f;
    border-color: #d4dbe8;
    box-shadow: none;
}

@media (min-width: 768px) {
    .whatsapp-quick-options {
        flex-wrap: nowrap;
    }

    .whatsapp-quick-option {
        flex: 1 1 0;
    }
}

@media (max-width: 640px) {
    .whatsapp-quick-modal-shell {
        width: min(94vw, 420px);
    }

    .whatsapp-quick-option {
        flex: 1 1 calc(50% - 4px);
    }

    .order-detail-audit-trigger span {
        display: none;
    }

    .order-detail-audit-popover {
        right: auto;
        left: 0;
        width: min(320px, calc(100vw - 48px));
    }
}

@media (max-width: 480px) {
    .whatsapp-quick-modal-body {
        padding: 2px 18px 16px;
    }

    .whatsapp-quick-option {
        flex: 1 1 100%;
    }
}

.order-detail-modal-body {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.order-detail-modal-heading {
    min-width: 0;
}

.order-detail-modal-header-actions .modal-close-btn {
    flex-shrink: 0;
}

.order-detail-modal-header-actions .btn {
    flex-shrink: 0;
}

.order-detail-modal-layout {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.order-detail-search-link i {
    font-size: 13px;
}

.order-detail-search-link span {
    white-space: nowrap;
}

.order-detail-modal-toolbar {
    justify-content: flex-end;
}

.order-detail-section-card {
    padding: 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.76);
    border: 1px solid rgba(180, 207, 221, 0.45);
    box-shadow: 0 16px 34px rgba(74, 88, 153, 0.08);
}

.order-voided-banner {
    background: #f7f7f7;
    border-color: #d5d5d5;
    color: #5f6368;
}

.order-voided-banner-chip {
    background: #ececec;
    border-color: #d5d5d5;
    color: #5f6368;
}

.order-voided-banner-copy {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    color: inherit;
}

.order-voided-banner-copy p {
    margin: 0;
}

.order-regularized-banner {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
    margin-bottom: 18px;
    padding: 12px 16px;
    border-radius: 14px;
    background: #f3f7ff;
    border: 1px solid #c9d9ff;
    color: #40527a;
}

.order-regularized-banner--card {
    margin-top: 2px;
}

.order-regularized-banner-chip {
    flex-shrink: 0;
    background: #eaf2ff;
    color: #3156a3;
    border: 1px solid #bfd4ff;
}

.order-regularized-banner-text {
    flex: 1;
    color: inherit;
    text-align: left;
}

.order-historical-regularization-banner--compact {
    align-items: center;
    justify-content: flex-start;
    text-align: left;
}

.order-historical-regularization-banner--compact .order-historical-regularization-copy {
    display: block;
    flex: 1;
    color: inherit;
    text-align: left;
    margin: 0;
}

.order-historical-regularization-banner--compact .order-historical-regularization-copy p {
    margin: 0;
    text-align: left;
}

.order-historical-regularization-banner--compact .order-historical-regularization-copy p:not(:first-child) {
    display: none;
}

@media (max-width: 640px) {
    .order-regularized-banner,
    .order-historical-regularization-banner--compact {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .order-historical-regularization-banner--compact .order-historical-regularization-copy {
        width: 100%;
    }
}

.order-detail-audit-menu {
    position: relative;
    flex-shrink: 0;
}

.order-detail-audit-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.order-detail-audit-popover {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 40;
    width: min(320px, 78vw);
    padding: 14px;
    border-radius: 18px;
    border: 1px solid rgba(180, 207, 221, 0.68);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 18px 34px rgba(74, 88, 153, 0.16);
    backdrop-filter: blur(14px);
}

.order-detail-audit-popover[hidden] {
    display: none !important;
}

.order-detail-audit-row {
    display: grid;
    gap: 4px;
}

.order-detail-audit-row + .order-detail-audit-row {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(180, 207, 221, 0.34);
}

.order-detail-audit-row span {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
}

.order-detail-audit-row strong {
    font-size: 14px;
    line-height: 1.45;
    color: var(--primary);
    overflow-wrap: anywhere;
    word-break: break-word;
}

.order-detail-section-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;
}

.order-detail-status-pill {
    flex-shrink: 0;
}

.order-detail-inline-void-action {
    display: none;
}

.order-void-warning {
    margin: 12px 0 0;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid rgba(180, 207, 221, 0.45);
    background: rgba(248, 250, 252, 0.96);
    color: #4b5563;
    font-weight: 600;
}

.order-void-actions {
    align-items: center;
}

.order-void-confirm-btn {
    background: #4b5563;
    border-color: #4b5563;
    color: #ffffff;
}

.order-void-confirm-btn:hover {
    background: #374151;
    border-color: #374151;
}

.mobile-order-code-pill-wrap {
    margin-top: 6px;
}

.order-detail-info-grid {
    margin-top: 14px;
}

.order-detail-totals-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.order-detail-services-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.order-detail-services-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 14px;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(246, 248, 255, 0.92);
    border: 1px solid rgba(194, 204, 232, 0.38);
    color: var(--muted);
}

.order-detail-services-summary-copy,
.order-detail-services-summary-progress {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.order-detail-services-summary strong {
    color: var(--primary);
    font-size: 14px;
}

.order-detail-services-summary span {
    font-size: 13px;
    text-align: right;
}

.order-detail-services-summary-copy span,
.order-detail-services-summary-progress span,
.order-detail-services-summary-progress small {
    font-size: 13px;
}

.order-detail-services-summary-progress {
    min-width: min(100%, 320px);
    align-items: flex-end;
}

.order-detail-services-global-status {
    width: fit-content;
}

.order-detail-progress-track {
    width: min(100%, 240px);
    height: 8px;
    border-radius: 999px;
    background: rgba(194, 204, 232, 0.55);
    overflow: hidden;
}

.order-detail-progress-track span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #7c93f0 0%, #4d63b5 100%);
}

.order-detail-service-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(194, 204, 232, 0.42);
}

.order-detail-service-row--ready {
    border-color: rgba(102, 126, 234, 0.42);
    box-shadow: 0 10px 22px rgba(102, 126, 234, 0.10);
}

.order-detail-service-row--delivered {
    border-color: rgba(74, 201, 138, 0.32);
    background: rgba(242, 253, 247, 0.9);
}

.order-detail-service-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(224, 232, 252, 0.72);
    color: var(--primary);
    font-size: 18px;
    flex: 0 0 44px;
}

.order-detail-service-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-detail-service-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.order-detail-service-copy strong {
    color: var(--primary);
    font-size: 16px;
}

.order-detail-service-status {
    flex: 0 0 auto;
    padding: 6px 10px;
    background: rgba(224, 232, 252, 0.72);
    border: 1px solid rgba(176, 194, 232, 0.6);
    color: var(--primary);
    text-transform: none;
    letter-spacing: 0;
}

.order-detail-service-side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.order-detail-service-action {
    margin: 0;
}

.order-detail-service-action .btn {
    white-space: nowrap;
}

.order-detail-service-detail,
.order-detail-service-meta {
    color: var(--muted);
    font-size: 13px;
}

.order-detail-service-meta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.order-detail-service-amount {
    text-align: right;
    color: var(--primary);
    font-size: 20px;
    font-weight: 700;
    white-space: nowrap;
}

.order-operational-in-progress {
    background: #eef2ff;
    color: #4256a6;
    border: 1px solid #ced7ff;
}

.order-operational-partial {
    background: #fff4db;
    color: #996300;
    border: 1px solid #f2d39a;
}

.order-operational-completed {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #a7f3d0;
}

.order-operational-pending,
.order-operational-ready,
.order-operational-delivered {
    text-transform: none;
    letter-spacing: 0;
}

.order-operational-pending {
    background: #f3f4f6;
    color: #4b5563;
    border: 1px solid #d1d5db;
}

.order-operational-ready {
    background: #e0ecff;
    color: #315aa6;
    border: 1px solid #bfd3ff;
}

.order-operational-delivered {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #a7f3d0;
}

.order-operational-summary-inline {
    display: block;
    margin-top: 4px;
}

.history-service-cell {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-detail-payments-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.order-detail-payment-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(246, 248, 255, 0.9);
    border: 1px solid rgba(180, 207, 221, 0.55);
}

.order-detail-payment-main,
.order-detail-payment-meta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.order-detail-payment-side {
    display: flex;
    align-items: center;
    gap: 12px;
}

.order-detail-payment-copy,
.order-detail-payment-meta {
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 4px;
}

.order-detail-payment-copy strong {
    color: var(--primary);
    font-size: 18px;
}

.order-detail-payment-amount-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.order-detail-payment-tooltip {
    width: 16px;
    height: 16px;
    color: #c7922f;
    opacity: 1;
    flex: 0 0 auto;
}

.order-detail-payment-tooltip::after {
    min-width: 220px;
    max-width: 260px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(47, 36, 64, 0.94);
    color: #f8f8fc;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.45;
    white-space: pre-line;
    box-shadow: 0 18px 28px rgba(47, 36, 64, 0.18);
}

.order-detail-payment-copy span,
.order-detail-payment-meta span {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.25;
}

.order-detail-payment-method {
    margin: 0;
    font-weight: 700;
}

.payment-method-edit-inline {
    margin-top: 12px;
}

.payment-method-edit-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    min-height: auto;
    border-radius: 12px;
    font-size: 13px;
    line-height: 1.2;
}

.payment-method-edit-btn-icon {
    justify-content: center;
    width: 36px;
    min-width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 12px;
}

.payment-method-edit-btn-icon i {
    margin: 0;
}

.payment-method-edit-summary {
    display: grid;
    gap: 10px;
    padding: 14px 16px;
    margin-bottom: 16px;
    border-radius: 16px;
    background: rgba(246, 248, 255, 0.9);
    border: 1px solid rgba(180, 207, 221, 0.55);
}

.payment-method-edit-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.payment-method-edit-summary-row span {
    color: var(--muted);
    font-size: 13px;
}

.payment-method-edit-summary-row strong {
    color: var(--primary);
    font-size: 14px;
}

.payment-method-efectivo {
    background: #dcfce7;
    color: #15803d;
}

.payment-method-plin {
    background: #dcfce7;
    color: #166534;
}

.payment-method-yape {
    background: #f3e8ff;
    color: #7e22ce;
}

.payment-method-tarjeta {
    background: #1f2937;
    color: #ffffff;
}

.price-config-board {
    display: grid;
    gap: 18px;
}

.price-configs-simple-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.price-config-quick-card,
.price-config-group-card {
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(249, 250, 255, 0.98) 100%);
    border: 1px solid rgba(180, 207, 221, 0.55);
    box-shadow: 0 16px 32px rgba(74, 88, 153, 0.08);
}

.price-config-quick-card {
    padding: 18px 18px 16px;
    display: grid;
    gap: 14px;
}

.price-config-quick-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.price-config-quick-head h4,
.price-config-group-head h4 {
    margin: 0;
    color: var(--primary);
    font-size: 22px;
    line-height: 1.1;
}

.price-config-unit-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(224, 232, 252, 0.78);
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.price-config-value {
    margin: 0;
    color: var(--primary);
    font-size: 40px;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1;
}

.price-config-quick-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.price-config-caption,
.price-config-group-head p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.price-config-btn {
    min-width: 120px;
}

.price-config-group-card {
    padding: 20px;
    display: grid;
    gap: 18px;
}

.price-config-group-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.price-config-chip-grid {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
}

.price-config-chip {
    display: grid;
    gap: 8px;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(248, 250, 255, 0.96);
    border: 1px solid rgba(194, 204, 232, 0.42);
}

.price-config-chip-label {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.price-config-chip-value {
    color: var(--primary);
    font-size: 24px;
    font-weight: 700;
    line-height: 1.1;
}

.price-config-edit-list {
    display: grid;
    gap: 14px;
}

.price-config-edit-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(180px, 220px) auto;
    gap: 14px;
    align-items: end;
    padding: 16px;
    border-radius: 16px;
    background: rgba(248, 250, 255, 0.92);
    border: 1px solid rgba(194, 204, 232, 0.42);
}

.price-config-edit-meta {
    display: grid;
    gap: 4px;
}

.price-config-edit-meta strong {
    color: var(--primary);
    font-size: 16px;
    padding-left: 8px
}

.price-config-edit-meta span {
    color: var(--muted);
    font-size: 13px;
    padding-bottom: 16px;
    padding-left: 8px
}

.price-config-edit-input {
    display: grid;
    gap: 6px;
}

.price-config-edit-actions {
    display: flex;
    align-items: end;
}

@media (max-width: 700px) {
    .order-detail-services-summary,
    .order-detail-service-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .order-detail-services-summary span {
        text-align: left;
    }

    .order-detail-services-summary-progress {
        min-width: 100%;
        align-items: flex-start;
    }

    .order-detail-progress-track {
        width: 100%;
    }

    .order-detail-service-row {
        grid-template-columns: 1fr;
        align-items: flex-start;
    }

    .order-detail-service-icon {
        margin-bottom: 2px;
    }

    .order-detail-service-amount {
        text-align: left;
    }

    .order-detail-service-side {
        align-items: flex-start;
    }

    .order-detail-payment-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .order-detail-modal-shell .modal-header {
        align-items: flex-start;
    }

    .order-detail-section-header {
        flex-direction: column;
        align-items: stretch;
    }

    .order-detail-modal-header-actions {
        width: 100%;
        justify-content: space-between;
    }

    .order-detail-payment-side,
    .order-detail-payment-main,
    .order-detail-payment-meta {
        width: 100%;
        justify-content: space-between;
    }

    .order-detail-payment-side {
        flex-direction: column;
        align-items: stretch;
    }

    .confirm-modal-actions,
    .order-ready-confirm-actions,
    .confirm-status-modal .confirm-status-actions {
        flex-direction: column-reverse;
    }

    .confirm-status-modal .confirm-status-content,
    .confirm-status-modal .confirm-status-body,
    .confirm-modal-card,
    .order-ready-confirm-body {
        padding: 0 20px 20px;
    }

    #allOrdersModal .modal-dialog.modal-content.modal-orders-wide {
        width: 98vw !important;
        max-width: 98vw !important;
        height: 88vh !important;
        max-height: 88vh !important;
    }

    #allOrdersModal .modal-header,
    #allOrdersModal .modal-body {
        padding-inline: 1rem;
    }

    #allOrdersModal .orders-total-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #allOrdersModal .orders-filter-search,
    #allOrdersModal .orders-filter-date,
    #allOrdersModal .orders-filter-sort,
    #allOrdersModal .orders-filter-status,
    #allOrdersModal .orders-filter-payment,
    #allOrdersModal .orders-filter-laundry,
    #allOrdersModal .orders-filter-actions {
        grid-column: auto;
    }

    #allOrdersModal .orders-filter-actions .btn {
        width: 100%;
        min-width: 0;
        margin-left: 0;
    }

    #allOrdersModal .table-container,
    #allOrdersModal .orders-total-table-shell {
        max-height: 50vh;
    }

    .dashboard-delayed-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-delayed-filter-search,
    .dashboard-delayed-filter-laundry,
    .dashboard-delayed-filter-start,
    .dashboard-delayed-filter-end,
    .dashboard-delayed-filter-sort,
    .dashboard-delayed-filter-actions {
        grid-column: auto;
    }

    #otherPendingOrdersModal .pending-other-filters,
    #otherPendingOrdersModal .pending-other-filters--no-laundry {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #otherPendingOrdersModal .pending-other-filter-actions {
        justify-content: stretch;
    }

    #otherPendingOrdersModal .pending-other-filter-actions .btn {
        width: 100%;
        min-width: 0;
    }

    .price-configs-simple-grid {
        grid-template-columns: 1fr;
    }

    .price-config-group-head,
    .price-config-quick-foot {
        flex-direction: column;
        align-items: flex-start;
    }

    .price-config-chip-grid {
        grid-template-columns: 1fr;
    }

    .price-config-edit-row {
        grid-template-columns: 1fr;
    }

    .price-config-quick-card,
    .price-config-group-card {
        padding: 18px;
    }
}

.delivery-debt-copy {
    margin: 0 0 16px;
    color: var(--text);
    line-height: 1.5;
}

.dashboard-audit-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.audit-notes-row td {
    background: rgba(248, 239, 246, 0.32);
    font-size: 14px;
    text-align: left;
}

.audit-modal-shell {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.audit-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.audit-filter-pills {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.audit-filter-pill {
    border: 1px solid rgba(85, 156, 173, 0.22);
    background: #fff;
    color: var(--primary);
    border-radius: 999px;
    padding: 9px 14px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.audit-filter-pill span {
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(85, 156, 173, 0.12);
    color: inherit;
    font-size: 12px;
}

.audit-filter-pill:hover,
.audit-filter-pill.is-active {
    background: rgba(85, 156, 173, 0.1);
    border-color: rgba(85, 156, 173, 0.38);
    box-shadow: 0 10px 22px rgba(85, 156, 173, 0.12);
}

.audit-toolbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.audit-modal-shell.is-resolved-view .audit-toolbar-actions,
.audit-modal-shell.is-resolved-view .audit-pending-only {
    display: none !important;
}

.audit-selection-count {
    font-weight: 600;
}

.audit-bulk-resolve-btn {
    background: var(--primary);
    color: #fff;
    border: 1px solid var(--primary);
    box-shadow: 0 10px 24px rgba(74, 88, 153, 0.18);
}

.audit-bulk-resolve-btn:hover:not(:disabled) {
    background: #3f4d8f;
    border-color: #3f4d8f;
    color: #fff;
}

.audit-bulk-resolve-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

.audit-history-table tbody tr[data-audit-row] {
    transition: background 0.2s ease;
}

.audit-history-table tbody tr[data-audit-row]:hover {
    background: rgba(85, 156, 173, 0.06);
}

.audit-history-table tbody tr[data-audit-row].is-selected td,
.audit-history-table tbody tr[data-audit-notes-row].is-selected td {
    background: rgba(248, 239, 246, 0.7);
}

.audit-check-col {
    width: 44px;
}

.audit-check-cell,
.audit-check-master {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.audit-check-cell input,
.audit-check-master input {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
    cursor: pointer;
}

.audit-status-chip.is-pending {
    background: rgba(236, 193, 68, 0.18);
    color: #8f6a05;
}

.audit-status-chip.is-resolved {
    background: rgba(46, 157, 87, 0.14);
    color: #1f7b49;
}

.audit-empty-state {
    border: 1px dashed rgba(85, 156, 173, 0.24);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    background: rgba(255, 255, 255, 0.5);
    color: var(--muted);
}

.toast-container {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1200;
    display: grid;
    gap: 0.8rem;
    width: min(100%, 420px);
    pointer-events: none;
}

@keyframes toastIn {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes toastOut {
    from { opacity: 1; transform: translateY(0); }
    to { opacity: 0; transform: translateY(-12px); }
}

.toast-message {
    padding: 0.95rem 1rem;
    border-radius: 18px;
    border: 1px solid rgba(85, 156, 173, 0.16);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 34px rgba(47, 36, 64, 0.12);
    font-weight: 600;
    color: var(--text);
    animation: toastIn 0.25s ease forwards;
    pointer-events: auto;
}

.toast-message.toast-hide {
    animation: toastOut 0.35s ease forwards;
}

.toast-success {
    background: var(--success);
    border-color: #98c8a9;
}

.toast-warning {
    background: var(--warning);
    border-color: #ddc27f;
}

.toast-danger,
.toast-error {
    background: var(--danger);
    border-color: #dfa8be;
}

.toast-info {
    background: var(--info);
    border-color: #8db9c6;
}

.helper-text {
    margin: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.context-disclaimer {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(74, 91, 168, 0.14);
    background: linear-gradient(180deg, rgba(246, 248, 255, 0.96) 0%, rgba(252, 253, 255, 0.98) 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.context-disclaimer .helper-text {
    color: rgba(77, 88, 132, 0.92);
    line-height: 1.5;
}

.context-disclaimer-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    flex: 0 0 32px;
    background: rgba(74, 91, 168, 0.1);
    color: var(--primary);
    font-size: 14px;
}

.context-disclaimer-order {
    margin-bottom: 16px;
    border-color: rgba(221, 194, 127, 0.48);
    background: linear-gradient(180deg, rgba(255, 249, 236, 0.96) 0%, rgba(255, 253, 246, 0.98) 100%);
}

.context-disclaimer-order .context-disclaimer-icon {
    background: rgba(221, 194, 127, 0.18);
    color: #a46a15;
}

.context-disclaimer-order .helper-text {
    color: #b27a1a;
    font-weight: 500;
}

.current-avatar-preview {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.current-avatar-preview img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    border: 1px solid rgba(85, 156, 173, 0.2);
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: visible;
}

.table-scroll,
.table-scroll-area {
    max-height: 280px;
    overflow-y: auto;
    overflow-x: auto;
    padding-right: 0.2rem;
}

.users-table-shell {
    max-height: calc(100vh - 260px);
}

.audit-modal .modal-body {
    display: flex;
    flex-direction: column;
}

.audit-table-shell {
    flex: 1;
    min-height: 0;
    max-height: none;
    overflow-y: visible;
}

.audit-modal .modal-scroll-area {
    overflow-y: auto;
    overflow-x: auto;
}

@media (max-width: 768px) {
    .audit-toolbar,
    .audit-toolbar-actions {
        align-items: stretch;
    }

    .audit-toolbar-actions {
        width: 100%;
        justify-content: stretch;
    }

    .audit-bulk-resolve-btn {
        width: 100%;
    }
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.9rem;
    background: rgba(255, 255, 255, 0.42);
    border-radius: 16px;
    overflow: hidden;
    table-layout: auto;
}

.data-table th,
.data-table td {
    padding: 0.95rem 0.8rem;
    text-align: center;
    border-bottom: 1px solid rgba(85, 156, 173, 0.2);
}

.data-table th {
    background: rgba(255, 255, 255, 0.38);
    color: var(--primary);
    font-weight: 700;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.inline-form {
    display: inline-flex;
    margin-left: 0.5rem;
}

.checkbox-group {
    align-items: flex-start;
}

.checkbox-inline {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    color: rgba(47, 36, 64, 0.86);
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    min-width: 20px;
    min-height: 20px;
    margin-top: 0.2rem;
}

.checkbox-inline input[type="checkbox"] {
    width: 16px;
    height: 16px;
    min-width: 16px;
    min-height: 16px;
    margin: 0;
}

.auth-page {
    display: grid;
    place-items: center;
    padding: 2rem;
}

.auth-shell {
    width: min(100%, 980px);
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(320px, 430px);
    gap: 1.5rem;
    align-items: center;
}

.auth-panel {
    padding: 2rem;
}

.login-left {
    max-width: 420px;
    width: 100%;
}

.login-logo-wrapper {
    width: 100%;
    display: flex;
    justify-content: flex-start;
}

.login-logo {
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    margin-bottom: 24px;
}

.fade-in {
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInLogin 0.6s ease-out forwards;
}

@keyframes fadeInLogin {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-description {
    margin-top: 0;
    line-height: 1.4;
}

.login-footer-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 12px;
}

.login-version {
    font-size: 12px;
    opacity: 0.6;
}

.login-disclaimer {
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    opacity: 0.5;
    text-align: center;
    pointer-events: none;
}

.auth-panel h1 {
    margin: 0.35rem 0 0.75rem;
    font-size: clamp(2rem, 4vw, 3.4rem);
    color: var(--primary);
}

.auth-panel p {
    max-width: 34ch;
}

.modal,
.modal-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: rgba(47, 36, 64, 0.42);
    z-index: 1300;
}

.modal.is-open,
.modal-overlay.is-open {
    display: flex;
}

.modal-dialog,
.modal-content {
    position: relative;
    width: min(100%, 1120px);
    height: min(86vh, 860px);
    max-height: 86vh;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 24px;
    box-shadow: 0 24px 48px rgba(47, 36, 64, 0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-content.large-modal,
#historyModal .modal-content,
.history-modal.modal-content {
    width: min(1400px, 96vw);
}

.search-history-modal-content {
    width: min(96vw, 1440px);
    max-width: 1440px;
}

.client-orders-history-modal {
    width: min(98vw, 1560px);
    max-width: 1560px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 4.5rem 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(85, 156, 173, 0.16);
}

.modal-header h3 {
    margin: 0;
    color: var(--primary);
}

.modal-close-btn {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: none;
    background: rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.modal-close-btn i {
    font-size: 16px;
}

.modal-close-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    transform: scale(1.05);
}

.modal-body,
.modal-scroll-area {
    padding: 1.25rem 1.5rem 1.5rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: auto;
}

.profile-avatar-modal {
    width: min(100%, 560px);
    height: auto;
    max-height: min(86vh, 720px);
}

.avatar-preview {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #da44a0;
    margin: 0 auto 20px;
    background: rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
}

.avatar-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.avatar-preview-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, var(--primary), var(--secondary));
    color: var(--white);
    font-size: 3rem;
    font-weight: 700;
}

@media (min-width: 1441px) {
    .sidebar {
        width: 236px;
        flex-basis: 236px;
    }

    .dashboard-main,
    .main-content {
        padding: 1.75rem;
    }

    .content-area,
    .page-content,
    .page-section,
    .responsive-grid {
        gap: 1.75rem;
    }
}

@media (max-width: 1200px) {
    .dashboard-frame {
        padding: 1rem;
    }

    .dashboard-shell,
    .app-layout {
        height: calc(100vh - 2rem);
    }

    .sidebar {
        width: 190px;
        flex-basis: 190px;
        padding: 18px 14px;
        height: 100%;
    }

    .sidebar-logo {
        min-height: 78px;
        height: 78px;
        padding: 10px 12px;
    }

    .sidebar-logo-img {
        max-width: 160px;
        height: 52px;
        max-height: 52px;
    }

    .sidebar-nav {
        gap: 8px;
        margin-top: 1rem;
    }

    .sidebar-link {
        min-height: 42px;
        padding: 10px 12px;
        font-size: 14px;
    }

    .dashboard-main,
    .main-content {
        padding: 16px;
    }

    .content-area,
    .page-content,
    .page-section,
    .responsive-grid {
        gap: 16px;
    }

    .topbar {
        padding: 18px 22px;
        gap: 16px;
    }

    .topbar-title,
    .page-title {
        font-size: clamp(28px, 3vw, 36px);
    }

    .header-actions,
    .topbar-actions {
        gap: 10px;
    }

    .header-datetime .time {
        font-size: 18px;
    }

    .content-card,
    .card {
        padding: 20px;
        border-radius: 20px;
    }

    .order-form-grid {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }
}

@media (max-width: 1100px) {
    .sidebar {
        width: 164px;
        flex-basis: 164px;
        padding: 16px 10px;
    }

    .sidebar-copy,
    .sidebar-user-copy {
        display: none;
    }

    .sidebar-user-card {
        justify-items: center;
        padding: 0.75rem;
    }

    .sidebar-user-main {
        justify-content: center;
    }

    .sidebar-avatar {
        width: 38px;
        height: 38px;
        flex-basis: 38px;
    }

    .sidebar-link {
        justify-content: center;
        padding-inline: 10px;
    }

    .sidebar-link-dot {
        display: none;
    }
}

@media (max-width: 900px) {
    .modal-filters-grid {
        grid-template-columns: 1fr;
    }

    .service-picker-layout {
        grid-template-columns: 1fr;
        min-height: auto;
    }

    .service-picker-sidebar {
        border-right: none;
        border-bottom: 1px solid rgba(85, 156, 173, 0.16);
        max-height: min(34vh, 280px);
        min-height: 0;
        padding-top: 16px;
        border-radius: 22px 22px 0 0;
    }

    .service-picker-detail {
        padding: 18px;
    }

    .service-picker-form-grid,
    .service-picker-heading {
        grid-template-columns: 1fr;
    }

    .service-compound-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .dashboard-shell,
    .app-layout {
        display: block;
        height: calc(100vh - 2rem);
    }

    .sidebar {
        display: none;
    }

    .dashboard-main,
    .main-content {
        width: 100%;
        padding: 14px;
        padding-bottom: 80px !important;
        min-height: 0;
    }

    .content-area,
    .page-content {
        padding-bottom: 0 !important;
    }

    .flash-messages,
    .toast-container,
    .alerts-container {
        position: fixed !important;
        top: calc(14px + env(safe-area-inset-top, 0px)) !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        width: min(92vw, 420px) !important;
        z-index: 99999 !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        pointer-events: none !important;
    }

    .mobile-toast,
    .toast-message,
    .flash-message,
    .alert {
        width: 100% !important;
        min-height: 58px !important;
        padding: 12px 14px !important;
        border-radius: 18px !important;
        display: grid !important;
        grid-template-columns: 38px minmax(0,1fr) 38px !important;
        align-items: center !important;
        gap: 12px !important;
        box-sizing: border-box !important;
        box-shadow: 0 12px 30px rgba(38,55,90,.14) !important;
        backdrop-filter: blur(12px) !important;
        pointer-events: auto !important;
        animation: mobileToastIn .22s ease-out both !important;
    }

    .mobile-toast-success,
    .toast-success,
    .alert-success,
    .flash-success {
        background: rgba(234,248,239,.96) !important;
        border: 1px solid rgba(180,230,195,.95) !important;
        color: #166534 !important;
    }

    .mobile-toast-danger,
    .mobile-toast-error,
    .toast-danger,
    .toast-error,
    .alert-danger,
    .flash-error {
        background: rgba(255,241,241,.97) !important;
        border: 1px solid rgba(255,195,195,.95) !important;
        color: #B91C1C !important;
    }

    .mobile-toast-warning,
    .toast-warning,
    .alert-warning,
    .flash-warning {
        background: rgba(255,248,224,.97) !important;
        border: 1px solid rgba(255,226,160,.95) !important;
        color: #9A5B00 !important;
    }

    .mobile-toast-info,
    .toast-info,
    .alert-info,
    .flash-info {
        background: rgba(238,244,255,.97) !important;
        border: 1px solid rgba(200,215,255,.95) !important;
        color: #304A9A !important;
    }

    .mobile-toast-icon {
        width: 38px !important;
        height: 38px !important;
        border-radius: 999px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: rgba(255,255,255,.7) !important;
        font-size: 17px !important;
        flex-shrink: 0 !important;
    }

    .mobile-toast-content {
        min-width: 0 !important;
        font-size: 14px !important;
        line-height: 1.3 !important;
        font-weight: 700 !important;
        overflow-wrap: anywhere !important;
    }

    .mobile-toast-close,
    .toast-message .btn-close {
        width: 36px !important;
        height: 36px !important;
        border: 0 !important;
        border-radius: 12px !important;
        background: rgba(255,255,255,.7) !important;
        color: inherit !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
        flex-shrink: 0 !important;
    }

    @keyframes mobileToastIn {
        from {
            opacity: 0;
            transform: translateY(-10px) scale(.98);
        }

        to {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }

    .topbar {
        flex-direction: column;
        align-items: flex-start;
        padding: 14px 16px;
        border-radius: 20px;
        gap: 8px;
        margin-bottom: 1rem;
    }

    .topbar-title,
    .page-title {
        font-size: 24px;
        line-height: 1.1;
    }

    .topbar-subtitle,
    .page-subtitle,
    .topbar-copy p {
        font-size: 12px;
        line-height: 1.35;
        margin-top: 2px;
    }

    .topbar-actions {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 8px;
        align-items: stretch;
    }

    .header-top-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: 10px;
        width: 100%;
    }

    .header-main-button {
        display: block;
        width: 100%;
    }

    .notifications-shell {
        width: auto;
    }

    .notification-button {
        align-self: flex-start;
    }

    .notifications-dropdown {
        position: fixed;
        left: 14px;
        right: 14px;
        top: auto;
        bottom: 92px;
        width: auto;
        max-height: 55vh;
        overflow-y: auto;
        border-radius: 24px;
        z-index: 1001;
    }

    .notification-item {
        display: grid;
        grid-template-columns: 32px 1fr auto;
        gap: 10px;
        align-items: center;
        min-height: 52px;
    }

    .notification-item span,
    .notification-item p,
    .notification-item-copy {
        white-space: normal;
        word-break: normal;
        overflow-wrap: break-word;
    }

    .mobile-bottom-nav {
        display: grid;
    }

    .header-datetime {
        align-items: flex-end;
        min-width: 0;
    }

    .header-datetime .time {
        font-size: 14px;
    }

    .header-datetime .date {
        font-size: 10px;
    }

    .header-main-button .btn,
    .header-main-button > a.btn,
    .header-main-button > button.btn {
        width: 100%;
        min-height: 44px;
    }

    .auth-shell,
    .admin-grid,
    .admin-actions-grid,
    .general-summary-grid,
    .form-grid,
    .cards-grid,
    .dashboard-grid,
    .summary-grid,
    .summary-two-columns,
    .content-area,
    .responsive-grid,
    .responsive-grid.two-cols,
    .responsive-grid.three-cols,
    .two-columns,
    .client-info-grid,
    .order-form-grid,
    .dashboard-hero {
        grid-template-columns: 1fr;
    }

    .section-head,
    .report-alert-head,
    .card-header-row,
    .filter-inline-row,
    .table-card-header,
    .table-card-controls,
    .operation-stat-header,
    .operation-stat-title-row,
    .dashboard-info-row,
    .total-day-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .closure-actions,
    .total-day-actions {
        justify-content: flex-start;
    }

    .total-day-actions,
    .delayed-orders-actions {
        width: 100%;
    }

    .delayed-orders-actions {
        width: auto;
        justify-content: flex-end;
        flex-wrap: nowrap;
        align-items: center;
    }

    .delayed-orders-content {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
    }

    .delayed-orders-count-stack {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 4px;
        text-align: right;
    }

    .delayed-orders-count-label {
        margin-top: 0;
    }

    .delayed-orders-action-desktop {
        display: none !important;
    }

    .delayed-orders-action-mobile-wrap {
        display: block;
        width: 100%;
        margin-top: 18px;
    }

    .delayed-orders-action-mobile {
        display: inline-flex;
        width: 100%;
        justify-content: center;
    }

    .card-header-row .btn {
        align-self: flex-start;
    }

    .admin-actions-row {
        width: 100%;
        flex-direction: column;
    }

    .modal {
        padding: 1rem;
    }

    .modal-content {
        width: 94vw;
        max-height: 86vh;
    }

    .modal-content.large-modal,
    #historyModal .modal-content,
    .history-modal.modal-content {
        width: 94vw;
    }

    .modal-scroll-area {
        max-height: 65vh;
        overflow-y: auto;
    }

    .modal-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .modal-close-btn {
        top: 12px;
        right: 12px;
    }

    .table-scroll-area {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table-scroll-area table,
    .table-wrapper table {
        min-width: 760px;
    }

    .content-card,
    .card {
        padding: 16px;
        border-radius: 22px;
    }

    .info-item {
        padding: 14px;
    }
}

@media (max-height: 800px) {
    .sidebar {
        padding-top: 18px;
        padding-bottom: 14px;
    }

    .sidebar-logo-img {
        max-width: 148px;
        height: 48px;
        max-height: 48px;
    }

    .sidebar-copy {
        font-size: 13px;
        line-height: 1.35;
        margin-bottom: 14px;
    }

    .sidebar-nav {
        gap: 6px;
    }

    .sidebar-link {
        padding: 9px 12px;
        font-size: 14px;
        min-height: 42px;
    }

    .sidebar-user-card {
        padding: 10px;
    }

    .sidebar-avatar {
        width: 34px;
        height: 34px;
        flex-basis: 34px;
    }

    .sidebar-logout {
        padding: 8px 10px;
        font-size: 12px;
    }

    .sidebar-user-name,
    .sidebar-user-name .first-name,
    .sidebar-user-name .last-name {
        font-size: 13px;
    }

    .sidebar-user-role {
        font-size: 12px;
    }

    .dashboard-main,
    .main-content {
        padding: 16px;
    }

    .topbar {
        padding: 18px 22px;
        margin-bottom: 16px;
    }

    .topbar-title,
    .page-title {
        font-size: 32px;
        line-height: 1.1;
    }

    .topbar-subtitle,
    .page-subtitle {
        font-size: 14px;
    }

    .content-card,
    .card {
        padding: 18px 20px;
        border-radius: 20px;
    }

    .page-content,
    .content-area,
    .page-section {
        gap: 16px;
    }

    input,
    select,
    textarea {
        min-height: 42px;
        padding: 10px 14px;
    }

    .btn {
        min-height: 42px;
        padding: 10px 18px;
    }
}

@media (max-width: 700px) {
    .actions-dropdown {
        width: 100%;
    }

    .actions-dropdown-toggle {
        width: 100%;
        justify-content: center;
    }

    .actions-dropdown-menu {
        left: 0;
        right: 0;
        min-width: 0;
    }

    .order-form-toolbar-actions {
        width: 100%;
    }

    .order-form-toolbar-actions .btn {
        flex: 1 1 100%;
        width: 100%;
    }

    .orders-header {
        flex-direction: column;
    }

    .orders-inline-filters {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
    }

    .orders-quick-toggle {
        width: 100%;
        justify-content: flex-start;
    }

    .orders-inline-filter-form {
        width: 100%;
        align-items: stretch;
        flex-wrap: wrap;
    }

    .filter-group-inline {
        flex: 1 1 100%;
    }

    .filter-group-inline select {
        width: 100%;
    }

    .order-form-grid,
    .client-info-grid,
    .form-grid,
    .third-party-form-grid,
    .third-party-filters,
    .third-party-metrics-grid,
    .responsive-grid.two-cols,
    .responsive-grid.three-cols {
        grid-template-columns: 1fr;
    }

    .third-party-form-card,
    .third-party-list-card,
    .metric-card {
        padding: 16px;
    }

    .order-services-card,
    .service-picker-sidebar,
    .service-picker-detail {
        padding: 16px;
    }

    .form-actions .btn,
    .content-card form .btn {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .client-info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .orders-header {
        flex-direction: column;
        gap: 10px;
    }

    .orders-header-left,
    .orders-header-right {
        width: 100%;
        max-width: none;
    }

    .orders-header-right {
        justify-content: flex-start;
    }

    .orders-inline-filters {
        width: 100%;
        justify-content: space-between;
    }

    .orders-quick-toggle {
        width: 100%;
        justify-content: flex-start;
    }

    .orders-inline-filter-form {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group-inline select,
    .orders-inline-filter-form .filter-btn {
        width: 100%;
        max-width: none;
    }

    .orders-filters-bar,
    .orders-filters-center {
        flex-direction: column;
        align-items: stretch;
    }

    .orders-filters-bar select,
    .orders-filters-bar .btn,
    .orders-filters-center select,
    .orders-filters-center .filter-btn {
        width: 100%;
        max-width: none;
    }
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
}

@media (max-width: 768px) {
    html,
    body {
        min-height: 100%;
        height: auto;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .dashboard-frame {
        padding: 10px;
        min-height: 100vh;
        height: auto;
        overflow-x: hidden;
        overflow-y: visible;
    }

    .dashboard-shell,
    .app-layout {
        min-height: calc(100vh - 20px);
        height: auto;
        min-height: calc(100vh - 20px);
        overflow: visible;
    }

    .dashboard-main,
    .main-content {
        min-height: 100vh;
        height: auto;
        padding: 12px;
        padding-bottom: 88px !important;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .page-section,
    .page-content,
    .content-area,
    .responsive-grid,
    .responsive-grid.two-cols,
    .responsive-grid.three-cols,
    .client-info-grid,
    .order-form-grid,
    .order-amounts-row,
    .form-grid,
    .third-party-form-grid,
    .third-party-filters,
    .third-party-metrics-grid,
    .admin-management-grid,
    .admin-sequence-grid {
        grid-template-columns: 1fr !important;
        gap: 14px;
    }

    .page-content,
    .content-area {
        padding-bottom: 96px !important;
        overflow: visible;
    }

    .topbar {
        padding: 14px 14px 16px;
        gap: 10px;
    }

    .topbar-copy,
    .topbar-actions,
    .header-actions,
    .header-main-button {
        width: 100%;
    }

    .header-top-row {
        width: 100%;
        gap: 8px;
        flex-wrap: wrap;
    }

    .header-datetime {
        margin-left: auto;
    }

    .content-card,
    .card,
    .summary-card,
    .general-summary-card,
    .admin-management-card,
    .total-day-card {
        padding: 16px;
        border-radius: 18px;
    }

    .section-head,
    .table-card-header,
    .orders-header,
    .order-services-header-actions,
    .order-form-toolbar,
    .service-compound-toolbar,
    .legacy-order-header,
    .header-orden-antigua {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .section-head .btn,
    .table-card-header .btn,
    .form-actions .btn,
    .order-submit-actions .btn,
    .header-main-button .btn,
    .header-main-button > a.btn,
    .header-main-button > button.btn,
    .order-services-header-actions .btn,
    .service-compound-toolbar .btn,
    .admin-actions-row .btn,
    .summary-actions .btn {
        width: 100%;
    }

    input,
    select,
    textarea,
    button.btn {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .modal,
    .modal-overlay {
        padding: 12px;
    }

    .modal-dialog,
    .modal-content,
    .large-modal,
    .history-modal.modal-content,
    .order-detail-modal-shell,
    .orders-modal-standard,
    .profile-avatar-modal {
        width: calc(100vw - 24px);
        max-width: calc(100vw - 24px);
        height: auto;
        max-height: calc(100vh - 24px);
    }

    .modal-body,
    .modal-scroll-area {
        padding: 14px;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .table-scroll-area,
    .table-wrapper {
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
    }

    .table-scroll-area table,
    .table-wrapper table,
    .data-table {
        min-width: 720px;
    }

    .data-table th,
    .data-table td {
        padding: 12px 10px;
        font-size: 13px;
    }

    .order-services-table-shell .data-table,
    .service-compound-table-shell .data-table {
        min-width: 640px;
    }

    .service-picker-modal {
        width: calc(100vw - 24px);
        max-width: calc(100vw - 24px);
        max-height: calc(100vh - 24px);
    }

    .service-picker-layout {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .service-picker-sidebar {
        border-right: 0;
        border-bottom: 1px solid rgba(85, 156, 173, 0.16);
        border-radius: 22px 22px 0 0;
        padding: 14px 14px 10px;
        max-height: none;
        background: rgba(248, 239, 246, 0.55);
    }

    .service-picker-list {
        display: flex;
        gap: 10px;
        overflow-x: auto;
        overflow-y: hidden;
        padding: 2px 2px 6px;
        scroll-snap-type: x proximity;
    }

    .service-picker-item {
        min-width: 220px;
        flex: 0 0 auto;
        scroll-snap-align: start;
        padding: 12px 14px;
    }

    .service-picker-detail {
        padding: 16px;
    }

    .service-picker-form-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .order-actions-dropdown,
    .actions-dropdown-menu {
        max-width: min(92vw, 280px);
    }

    .mobile-bottom-nav {
        padding-bottom: max(10px, var(--safe-area-bottom));
    }

    .chart-shell {
        min-height: 240px;
    }

    .dashboard-indicators-card .chart-shell,
    .donut-chart-shell {
        min-height: 230px;
    }

    .chart-empty-state {
        min-height: 180px;
        font-size: 13px;
    }

    .reports-chart-shell {
        height: 220px;
        min-height: 220px;
        max-height: 220px;
    }

    .fab-button {
        pointer-events: auto;
    }
}

@media (max-width: 480px) {
    .dashboard-frame {
        padding: 8px;
    }

    .dashboard-main,
    .main-content {
        min-height: 100vh;
        height: auto;
        padding: 10px;
        padding-bottom: 92px !important;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .topbar {
        padding: 12px;
        border-radius: 16px;
    }

    .topbar-title,
    .page-title {
        font-size: 22px;
    }

    .topbar-subtitle,
    .page-subtitle,
    .topbar-copy p {
        font-size: 12px;
    }

    .content-card,
    .card,
    .summary-card,
    .general-summary-card,
    .admin-management-card,
    .total-day-card {
        padding: 14px;
        border-radius: 16px;
    }

    .section-title {
        font-size: 1.05rem;
    }

    .section-subtitle,
    .helper-text {
        font-size: 12px;
    }

    .btn {
        min-height: 44px;
        padding: 10px 14px;
        font-size: 14px;
    }

    input,
    select,
    textarea {
        min-height: 44px;
        padding: 10px 12px;
        font-size: 14px;
    }

    .auth-page {
        padding: 14px;
    }

    .auth-shell {
        grid-template-columns: 1fr;
        gap: 14px;
        width: 100%;
    }

    .auth-panel,
    .login-left {
        max-width: none;
        width: 100%;
        padding: 18px 16px;
    }

    .login-logo {
        margin-bottom: 18px;
    }

    .login-disclaimer {
        position: static;
        transform: none;
        margin-top: 10px;
        opacity: 0.7;
    }

    .table-scroll-area table,
    .table-wrapper table,
    .data-table {
        min-width: 640px;
    }

    .client-search-results,
    .actions-dropdown-menu,
    .order-actions-dropdown {
        right: 0;
        left: 0;
        width: auto;
        max-width: none;
    }

    .service-picker-item {
        min-width: 200px;
    }

    .client-results-modal-card,
    .service-picker-modal,
    .history-modal.modal-content,
    .order-detail-modal-shell {
        width: calc(100vw - 16px);
        max-width: calc(100vw - 16px);
        max-height: calc(100vh - 16px);
    }

    .client-search-card,
    .client-search-card .form,
    .client-search-card .form-grid,
    .client-search-card .client-search-group,
    .client-search-card .client-search-shell {
        overflow: visible !important;
    }

    .client-search-card .client-search-group {
        position: relative;
        z-index: 60;
    }

    .client-search-card .client-search-results {
        top: calc(100% + 6px);
        max-height: min(34vh, 240px);
        padding: 6px;
        border-radius: 14px;
        z-index: 1300;
    }

    .client-search-card .client-search-result-item {
        padding: 9px 10px;
        gap: 10px;
    }

    .client-search-card .client-search-result-name {
        font-size: 0.9rem;
    }

    .client-search-card .client-search-result-meta {
        gap: 6px;
        font-size: 0.78rem;
    }

    .client-search-card .client-search-result-right {
        flex-shrink: 0;
    }

    .client-search-card .client-dni-pill {
        min-width: 84px;
        padding: 5px 10px;
        font-size: 13px;
    }
}

@media (max-width: 360px) {
    .dashboard-frame {
        padding: 6px;
    }

    .dashboard-main,
    .main-content {
        min-height: 100vh;
        height: auto;
        padding: 8px;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .topbar,
    .content-card,
    .card {
        padding: 12px;
        border-radius: 14px;
    }

    .topbar-title,
    .page-title {
        font-size: 20px;
    }

    .btn,
    input,
    select,
    textarea {
        font-size: 13px;
    }

    .mobile-bottom-nav {
        grid-template-columns: repeat(6, minmax(0, 1fr));
        gap: 4px;
        padding-inline: 6px;
    }

    .mobile-nav-item {
        font-size: 10px;
    }

    .service-picker-item {
        min-width: 184px;
    }

    .client-dni-pill,
    .legacy-order-tag,
    .pill-chip {
        min-width: 0;
        padding-inline: 10px;
        font-size: 12px;
    }
}

@media (max-width: 768px) {
    .topbar.dashboard-mobile-compact {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "greeting notifications"
            "title time"
            "cta cta";
        align-items: center;
        gap: 8px 10px;
        padding: 12px 14px;
    }

    .topbar.dashboard-mobile-compact .topbar-copy,
    .topbar.dashboard-mobile-compact .topbar-actions,
    .topbar.dashboard-mobile-compact .header-top-row,
    .topbar.dashboard-mobile-compact .header-main-button {
        display: contents;
    }

    .topbar.dashboard-mobile-compact .topbar-greeting {
        grid-area: greeting;
        margin: 0;
        font-size: 12px;
        line-height: 1.2;
    }

    .topbar.dashboard-mobile-compact .notifications-shell {
        grid-area: notifications;
        justify-self: end;
    }

    .topbar.dashboard-mobile-compact .topbar-title {
        grid-area: title;
        font-size: 18px;
        line-height: 1.2;
    }

    .topbar.dashboard-mobile-compact .topbar-subtitle {
        display: none;
    }

    .topbar.dashboard-mobile-compact .header-datetime {
        grid-area: time;
        justify-self: end;
        text-align: right;
        margin: 0;
    }

    .topbar.dashboard-mobile-compact .header-datetime .time {
        font-size: 14px;
        line-height: 1.2;
    }

    .topbar.dashboard-mobile-compact .header-datetime .date {
        font-size: 11px;
        line-height: 1.2;
    }

    .topbar.dashboard-mobile-compact .header-main-button {
        grid-area: cta;
    }

    .topbar.dashboard-mobile-compact .header-main-button .btn,
    .topbar.dashboard-mobile-compact .header-main-button > a.btn,
    .topbar.dashboard-mobile-compact .header-main-button > button.btn {
        width: 100%;
        min-height: 44px;
        margin-top: 2px;
        border-radius: 12px;
        font-size: 14px;
    }

    .topbar.dashboard-mobile-compact .notification-button {
        width: 38px;
        height: 38px;
    }

    .topbar.dashboard-mobile-compact .notification-badge {
        min-width: 18px;
        height: 18px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .topbar.dashboard-mobile-compact {
        padding: 12px;
        gap: 7px 8px;
    }

    .topbar.dashboard-mobile-compact .topbar-greeting {
        font-size: 12px;
    }

    .topbar.dashboard-mobile-compact .topbar-title {
        font-size: 18px;
    }
}

.fab-button {
    position: fixed;
    right: 16px;
    bottom: 80px;
    width: 56px;
    height: 56px;
    border-radius: 999px;
    background: #e91e63;
    color: #ffffff;
    border: none;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    line-height: 1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 1000;
}

.fab-button.show {
    display: inline-flex;
}

@media (max-width: 768px) {
    .topbar.dashboard-mobile-collapsible {
        position: sticky;
        top: 0;
        z-index: 100;
        background: rgba(255, 255, 255, 0.96);
        transition: padding 0.3s ease, gap 0.3s ease, box-shadow 0.3s ease;
        backdrop-filter: blur(10px);
    }

    .topbar.dashboard-mobile-collapsible.expanded {
        padding-top: 12px;
        padding-bottom: 12px;
    }

    .topbar.dashboard-mobile-collapsible.collapsed {
        padding: 8px 12px;
        gap: 6px 10px;
        box-shadow: 0 10px 24px rgba(74, 88, 153, 0.1);
    }

    .topbar.dashboard-mobile-collapsible .topbar-greeting {
        transition: opacity 0.2s ease;
    }

    .topbar.dashboard-mobile-collapsible.collapsed .topbar-greeting {
        display: none;
    }

    .topbar.dashboard-mobile-collapsible.collapsed .topbar-title {
        font-size: 16px;
    }

    .topbar.dashboard-mobile-collapsible.collapsed .header-datetime .time {
        font-size: 12px;
    }

    .topbar.dashboard-mobile-collapsible.collapsed .header-main-button .btn,
    .topbar.dashboard-mobile-collapsible.collapsed .header-main-button > a.btn,
    .topbar.dashboard-mobile-collapsible.collapsed .header-main-button > button.btn {
        display: none;
    }

    .topbar.dashboard-mobile-collapsible .header-main-button .btn-nueva-orden,
    .topbar.dashboard-mobile-collapsible .header-main-button > a.btn-nueva-orden {
        width: 100%;
        min-height: 44px;
        border-radius: 12px;
        font-size: 14px;
        margin-top: 8px;
    }

    .fab-button {
        display: none;
    }
}

@media (min-width: 768px) {
    .fab-button {
        display: none !important;
    }
}

@media (max-width: 767px) {
    :root {
        --mobile-nav-height: 72px;
        --mobile-nav-bottom: 8px;
        --mobile-final-gap: 16px;
    }

    .topbar.has-brand-header-background,
    .mobile-page-header.has-brand-header-background {
        background-image: var(--brand-header-bg-image);
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
    }

    html,
    body {
        min-height: 100%;
        height: auto;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .dashboard-main,
    .main-content,
    main,
    .dashboard-content,
    .app-content,
    .dashboard-wrapper,
    .dashboard-page,
    .dashboard-layout,
    .content-wrapper {
        min-height: auto !important;
        height: auto !important;
        overflow-x: hidden;
        overflow-y: auto;
        padding-bottom: calc(
            var(--mobile-nav-height) +
            var(--mobile-nav-bottom) +
            var(--mobile-final-gap)
        ) !important;
        margin-bottom: 0 !important;
    }

    .page-content,
    .content-area {
        min-height: auto !important;
        height: auto !important;
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
    }

    .dashboard-frame,
    .dashboard-shell,
    .app-layout,
    .dashboard-wrapper,
    .dashboard-page,
    .dashboard-layout {
        min-height: auto !important;
        height: auto !important;
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
    }

    .bottom-nav,
    .mobile-bottom-nav,
    .bottom-menu {
        height: var(--mobile-nav-height);
        position: fixed;
        left: 8px;
        right: 8px;
        bottom: var(--mobile-nav-bottom);
        z-index: 1000;
    }

    .dashboard-stats,
    .stats-grid,
    .kpi-section,
    .dashboard-kpis,
    .admin-grid,
    .quick-access-section {
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
    }

    .dashboard-stats > :last-child,
    .stats-grid > :last-child,
    .kpi-section > :last-child,
    .dashboard-kpis > :last-child,
    .admin-grid > :last-child,
    .quick-access-section > :last-child,
    .kpi-card:last-child,
    .dashboard-kpi-card:last-child,
    .metric-card:last-child,
    .stat-card:last-child {
        margin-bottom: 0 !important;
    }

    .bottom-spacer,
    .mobile-spacer,
    .nav-spacer,
    .safe-area-spacer,
    .footer-spacer {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    main::after,
    .main-content::after,
    .page-content::after,
    .dashboard-content::after,
    .app-content::after {
        display: none !important;
        content: none !important;
        height: 0 !important;
    }

    .card:last-child,
    .dashboard-card:last-child,
    .kpi-card:last-child {
        margin-bottom: 0;
    }

    .mobile-page-header {
        position: sticky;
        top: 8px;
        z-index: 900;
        margin: 8px 0 12px;
        padding: 14px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(10px);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 24px rgba(38, 55, 90, 0.08);
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "greeting notification"
            "title time"
            "subtitle time"
            "cta cta";
        align-items: start;
        gap: 0;
    }

    .mobile-page-header .topbar-copy,
    .mobile-page-header .topbar-actions,
    .mobile-page-header .header-top-row {
        display: contents;
    }

    .mobile-greeting,
    .mobile-header-eyebrow {
        grid-area: greeting;
        margin: 0 0 6px;
        font-size: 12px;
        line-height: 1.2;
        font-weight: 700;
        color: #E02D8A;
    }

    .mobile-page-title {
        grid-area: title;
        margin: 0;
        font-size: 22px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
        min-width: 0;
    }

    .mobile-header-subtitle {
        grid-area: subtitle;
        margin: 2px 0 0;
        font-size: 11px;
        line-height: 1.2;
        color: #7B7188;
        min-width: 0;
    }

    .mobile-header-notification {
        grid-area: notification;
        width: 40px;
        height: 40px;
        flex: 0 0 40px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        justify-self: end;
        margin-top: -2px;
    }

    .mobile-header-time-block {
        grid-area: time;
        flex: 0 0 auto;
        text-align: right;
        margin-top: 2px;
    }

    .mobile-header-time {
        display: block;
        font-size: 13px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
        white-space: nowrap;
    }

    .mobile-header-date {
        display: block;
        margin-top: 2px;
        font-size: 10px;
        line-height: 1.1;
        color: #8B8297;
        white-space: nowrap;
    }

    .mobile-primary-cta-shell {
        grid-area: cta;
    }

    .mobile-primary-cta,
    .btn-nueva-orden,
    .mobile-page-header .header-main-button .btn,
    .mobile-page-header .header-main-button > a.btn,
    .mobile-page-header .header-main-button > button.btn {
        width: 100%;
        min-height: 42px;
        margin-top: 12px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }

    .mobile-page-header.is-collapsed {
        padding: 8px 12px;
        min-height: 56px;
        grid-template-areas: "title notification";
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
    }

    .mobile-page-header.is-collapsed .mobile-header-expanded-only,
    .mobile-page-header.is-collapsed .mobile-header-subtitle,
    .mobile-page-header.is-collapsed .mobile-header-time-block,
    .mobile-page-header.is-collapsed .mobile-primary-cta,
    .mobile-page-header.is-collapsed .btn-nueva-orden,
    .mobile-page-header.is-collapsed .header-main-button {
        display: none !important;
    }

    .mobile-page-header.is-collapsed .mobile-page-title {
        font-size: 17px;
    }

    .mobile-page-header,
    .mobile-page-header .topbar-actions,
    .mobile-page-header .notifications-shell {
        overflow: visible;
    }

    .mobile-page-header .notifications-dropdown {
        position: absolute;
        top: calc(100% + 10px);
        right: 0;
        left: auto;
        bottom: auto;
        width: min(320px, calc(100vw - 32px));
        max-width: calc(100vw - 32px);
        max-height: min(50vh, 420px);
        overflow-y: auto;
        overflow-x: hidden;
        padding: 12px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.99);
        border: 1px solid rgba(74, 88, 153, 0.12);
        box-shadow: 0 18px 36px rgba(47, 36, 64, 0.18);
        z-index: 1400;
    }

    .mobile-page-header .notifications-list {
        margin-top: 10px;
    }

    .mobile-page-header .notification-item {
        padding: 12px;
        border-radius: 14px;
    }

    .mobile-page-header .notification-item-copy {
        font-size: 0.9rem;
        line-height: 1.3;
    }

    .fab-button {
        bottom: calc(var(--mobile-nav-height) + var(--mobile-safe-bottom) + 10px);
        pointer-events: auto;
    }

    .card,
    .dashboard-card,
    .quick-card,
    .kpi-card,
    .info-card,
    .content-card,
    .metric-card {
        width: 100%;
        box-sizing: border-box;
        overflow: hidden;
        border-radius: 14px;
        padding: 16px;
    }

    .quick-link-card,
    .quick-card {
        display: flex;
        align-items: center;
        gap: 14px;
        min-height: auto;
    }

    .quick-link-card .quick-link-icon,
    .quick-card-icon {
        flex: 0 0 52px;
        width: 52px;
        height: 52px;
    }

    .quick-link-card > div,
    .quick-card-content {
        flex: 1;
        min-width: 0;
    }

    .quick-link-title,
    .quick-card-title {
        font-size: 17px;
        line-height: 1.2;
        margin-bottom: 4px;
    }

    .quick-link-text,
    .quick-card-description {
        font-size: 14px;
        line-height: 1.35;
    }

    .admin-grid > .metric-card {
        min-height: 72px !important;
        padding: 16px 18px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 16px !important;
    }

    .admin-grid > .metric-card .metric-label {
        margin: 0 !important;
        font-size: 13px !important;
        line-height: 1.2 !important;
        letter-spacing: 0.03em !important;
        text-transform: uppercase;
        flex: 1;
    }

    .admin-grid > .metric-card .metric-value {
        margin: 0 !important;
        font-size: 32px !important;
        line-height: 1 !important;
        font-weight: 700 !important;
        text-align: right !important;
        flex: 0 0 auto;
    }

    .dashboard-hero {
        gap: 12px !important;
    }

    .dashboard-hero .section-header {
        gap: 4px;
        margin-bottom: 0;
    }

    .dashboard-hero .section-subtitle {
        margin-top: 2px;
    }

    .dashboard-user-card {
        padding: 0.7rem 0.9rem;
        border-radius: 18px;
    }

    .dashboard-user-meta {
        gap: 8px;
    }

    .dashboard-user-meta strong {
        font-size: 0.94rem;
    }

    .dashboard-user-meta .divider {
        height: 14px;
    }

    button,
    .btn,
    .button,
    .primary-button,
    .secondary-button {
        min-height: 44px;
        font-size: 14px;
        border-radius: 12px;
    }

    .btn-sm,
    .small-button {
        min-height: 36px;
        padding: 8px 12px;
        font-size: 13px;
    }
}

@media (max-width: 767px) {
    :root {
        --mobile-nav-height: 72px;
        --mobile-nav-bottom: 8px;
        --mobile-final-gap: 16px;
        --mobile-safe-bottom: var(--safe-area-bottom);
    }

    html,
    body {
        overflow-x: hidden !important;
        overflow-y: auto !important;
    }

    body {
        padding-top: var(--safe-area-top);
        padding-bottom: var(--safe-area-bottom);
    }

    .dashboard-frame,
    .dashboard-shell,
    .app-layout,
    .dashboard-wrapper,
    .dashboard-page,
    .dashboard-layout,
    main,
    .dashboard-main,
    .main-content,
    .content-wrapper {
        min-height: auto !important;
        height: auto !important;
        margin-bottom: 0 !important;
    }

    .dashboard-frame,
    .dashboard-shell,
    .app-layout {
        min-height: 100dvh !important;
    }

    .dashboard-main,
    .main-content {
        overflow: hidden !important;
        padding: 12px 12px 0 !important;
    }

    .page-content,
    .content-area,
    .dashboard-content,
    .app-content {
        width: 100% !important;
        min-height: 0 !important;
        height: auto !important;
        flex: 1 1 auto !important;
        overflow-x: visible !important;
        overflow-y: auto !important;
        gap: 12px !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
        padding-bottom: calc(
            var(--mobile-nav-height) +
            var(--mobile-nav-bottom) +
            var(--mobile-final-gap) +
            var(--mobile-safe-bottom)
        ) !important;
        margin-bottom: 0 !important;
    }

    .page-content > *,
    .content-area > * {
        min-width: 0;
    }

    .bottom-spacer,
    .mobile-spacer,
    .nav-spacer,
    .safe-area-spacer,
    .footer-spacer {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    main::after,
    .main-content::after,
    .page-content::after,
    .dashboard-content::after,
    .app-content::after {
        display: none !important;
        content: none !important;
        height: 0 !important;
    }

    .mobile-page-header {
        position: sticky;
        top: 8px;
        z-index: 900;
        margin: 8px 0 12px;
        padding: 14px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(10px);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 24px rgba(38, 55, 90, 0.08);
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) auto;
        grid-template-areas:
            "greeting notification"
            "title time"
            "subtitle time"
            "cta cta";
        align-items: start;
        gap: 0;
        transition: padding 0.24s ease, border-radius 0.24s ease, box-shadow 0.24s ease;
        overflow: visible !important;
    }

    .mobile-page-header .topbar-copy,
    .mobile-page-header .topbar-actions,
    .mobile-page-header .header-main-button,
    .mobile-page-header .mobile-header-top-row {
        display: contents !important;
    }

    .mobile-title-inline {
        grid-area: title;
        display: flex;
        align-items: flex-start;
        gap: 0;
        min-width: 0;
    }

    .mobile-greeting,
    .mobile-header-eyebrow {
        grid-area: greeting;
        margin: 0 0 6px;
        font-size: 12px;
        line-height: 1.2;
        font-weight: 700;
        color: #E02D8A;
    }

    .mobile-page-title {
        margin: 0;
        font-size: 22px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
        min-width: 0;
        flex: 1;
    }

    .mobile-header-subtitle {
        grid-area: subtitle;
        margin: 2px 0 0;
        font-size: 11px;
        line-height: 1.2;
        color: #7B7188;
        min-width: 0;
    }

    .mobile-header-time-block {
        grid-area: time;
        flex: 0 0 auto;
        text-align: right;
        margin-top: 2px;
    }

    .mobile-header-time {
        display: block;
        font-size: 13px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
        white-space: nowrap;
    }

    .mobile-header-date {
        display: block;
        margin-top: 2px;
        font-size: 10px;
        line-height: 1.1;
        color: #8B8297;
        white-space: nowrap;
    }

    .mobile-header-notification {
        grid-area: notification;
        width: 40px;
        height: 40px;
        flex: 0 0 40px;
        justify-self: end;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin-top: -2px;
    }

    .mobile-page-header .notification-button {
        width: 40px;
        height: 40px;
    }

    .mobile-primary-cta-shell {
        grid-area: cta;
    }

    .mobile-primary-cta,
    .btn-nueva-orden,
    .mobile-page-header .header-main-button .btn,
    .mobile-page-header .header-main-button > a.btn,
    .mobile-page-header .header-main-button > button.btn {
        width: 100%;
        min-height: 42px;
        margin-top: 12px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }

    .mobile-header-menu-btn {
        width: 40px;
        height: 40px;
        border: 0;
        background: transparent;
        color: #304A9A;
        font-size: 24px;
        display: none;
        align-items: center;
        justify-content: center;
        flex: 0 0 40px;
        margin: -8px 0 0 -8px;
    }

    .mobile-page-header.is-collapsed {
        padding: 8px 12px;
        min-height: 56px;
        border-radius: 16px;
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.14);
        grid-template-areas:
            "title notification";
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
    }

    .mobile-page-header.is-collapsed .mobile-greeting,
    .mobile-page-header.is-collapsed .mobile-header-subtitle,
    .mobile-page-header.is-collapsed .mobile-header-time-block,
    .mobile-page-header.is-collapsed .mobile-primary-cta,
    .mobile-page-header.is-collapsed .btn-nueva-orden,
    .mobile-page-header.is-collapsed .header-main-button {
        display: none !important;
    }

    .mobile-page-header.is-collapsed .mobile-page-title {
        font-size: 17px;
    }

    .mobile-page-header.is-collapsed .mobile-title-inline {
        align-items: center;
        gap: 8px;
    }

    .mobile-page-header.is-collapsed .mobile-header-menu-btn {
        display: inline-flex;
    }

    .mobile-page-header .notifications-shell,
    .mobile-page-header .notifications-dropdown {
        overflow: visible;
    }

    .mobile-page-header .notifications-dropdown {
        position: absolute;
        top: calc(100% + 10px);
        right: 0;
        left: auto;
        width: min(320px, calc(100vw - 32px));
        max-width: calc(100vw - 32px);
        max-height: min(50vh, 420px);
        overflow-y: auto;
        border-radius: 18px;
        z-index: 1400;
    }

    .mobile-fab-new-order {
        position: fixed;
        right: 18px;
        bottom: calc(72px + 24px + env(safe-area-inset-bottom, 0px));
        width: 56px;
        height: 56px;
        border-radius: 999px;
        border: 0;
        background: #4A5BA8;
        color: #fff;
        font-size: 32px;
        line-height: 1;
        display: none;
        align-items: center;
        justify-content: center;
        z-index: 1001;
        box-shadow: 0 10px 24px rgba(38, 55, 90, 0.24);
    }

    .mobile-fab-new-order.is-visible {
        display: flex;
    }

    .bottom-nav,
    .mobile-bottom-nav,
    .bottom-menu {
        position: fixed;
        left: 8px;
        right: 8px;
        bottom: calc(var(--mobile-nav-bottom) + var(--mobile-safe-bottom));
        height: var(--mobile-nav-height);
        z-index: 1000;
    }

    .admin-grid > .metric-card {
        min-height: 68px !important;
        padding: 14px 18px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 16px !important;
    }

    .admin-grid > .metric-card .metric-label {
        margin: 0 !important;
        font-size: 13px !important;
        line-height: 1.2 !important;
        letter-spacing: 0.03em !important;
        text-transform: uppercase;
        flex: 1;
    }

    .admin-grid > .metric-card .metric-value {
        margin: 0 !important;
        font-size: 32px !important;
        line-height: 1 !important;
        font-weight: 700 !important;
        text-align: right !important;
        flex: 0 0 auto;
    }

    .card,
    .dashboard-card,
    .quick-card,
    .info-card,
    .content-card {
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
        overflow: hidden;
        border-radius: 14px;
    }

    .quick-link-card,
    .quick-card {
        display: flex;
        align-items: center;
        gap: 14px;
        min-height: auto;
    }

    .quick-link-card .quick-link-icon,
    .quick-card-icon {
        flex: 0 0 52px;
        width: 52px;
        height: 52px;
    }

    .quick-link-card > div,
    .quick-card-content {
        flex: 1;
        min-width: 0;
    }

    .quick-link-title,
    .quick-card-title {
        font-size: 17px;
        line-height: 1.2;
        margin-bottom: 4px;
    }

    .quick-link-text,
    .quick-card-description {
        font-size: 14px;
        line-height: 1.35;
    }

    button,
    .btn,
    .button,
    .primary-button,
    .secondary-button {
        min-height: 44px;
        font-size: 14px;
        border-radius: 12px;
    }

    .btn-sm,
    .small-button {
        min-height: 36px;
        padding: 8px 12px;
        font-size: 13px;
    }

    .autocomplete-wrapper,
    .search-wrapper,
    .input-search-wrapper {
        position: relative;
        overflow: visible !important;
    }

    .autocomplete-dropdown,
    .autocomplete-results,
    .search-suggestions {
        position: absolute;
        left: 0;
        right: 0;
        top: 100%;
        z-index: 9999;
        max-height: 240px;
        overflow-y: auto;
        border-radius: 12px;
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    }

    .mobile-stack {
        display: grid;
        gap: 12px;
    }

    .mobile-section {
        display: grid;
        gap: 16px;
        margin-bottom: 24px;
    }

    .mobile-card,
    .mobile-list-item,
    .mobile-order-card,
    .mobile-payment-item,
    .mobile-expense-item,
    .mobile-summary-card,
    .mobile-movement-item {
        display: grid;
        gap: 8px;
        padding: 14px 16px;
        border-radius: 14px;
        background: rgba(255, 255, 255, 0.96);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
    }

    .mobile-status-pill {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 28px;
        padding: 4px 10px;
        border-radius: 999px;
        font-size: 11px;
        font-weight: 700;
        line-height: 1;
        white-space: nowrap;
    }

    .mobile-quick-actions,
    .mobile-bottom-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        align-items: center;
    }

    .mobile-bottom-actions > * {
        flex: 1 1 140px;
    }

    .mobile-filter-chips {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    .mobile-filter-sheet {
        display: grid;
        gap: 12px;
        padding: 14px;
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid rgba(210, 225, 235, 0.9);
    }

    .mobile-empty-state {
        display: grid;
        gap: 6px;
        justify-items: start;
        padding: 16px;
        border-radius: 14px;
        background: rgba(248, 245, 255, 0.72);
        border: 1px dashed rgba(74, 91, 168, 0.22);
        color: #6f6780;
        text-align: left;
    }

    .modal-filters-grid,
    .history-filters,
    .orders-total-filters,
    .dashboard-delayed-filters {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
        align-items: stretch !important;
    }

    .modal-filters-grid .filter-group,
    .history-filters .filter-group,
    .modal-filters-grid .history-filter-group,
    .history-filters .history-filter-group {
        min-width: 0;
    }

    .modal-filters-grid .btn,
    .history-filters .btn {
        width: 100%;
    }

    .table-wrapper,
    .table-scroll-area {
        overflow: visible !important;
    }

    .data-table.mobile-card-table,
    .data-table.mobile-card-table thead,
    .data-table.mobile-card-table tbody,
    .data-table.mobile-card-table tr,
    .data-table.mobile-card-table th,
    .data-table.mobile-card-table td {
        display: block;
        width: 100%;
    }

    .data-table.mobile-card-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .data-table.mobile-card-table tbody {
        display: grid;
        gap: 12px;
    }

    .data-table.mobile-card-table tbody tr {
        padding: 14px 16px;
        border-radius: 14px;
        background: rgba(255, 255, 255, 0.96);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
    }

    .data-table.mobile-card-table tbody td {
        border: 0 !important;
        padding: 0 !important;
        margin: 0 0 10px;
        min-width: 0;
    }

    .data-table.mobile-card-table tbody td:last-child {
        margin-bottom: 0;
    }

    .data-table.mobile-card-table tbody td::before {
        content: attr(data-mobile-label);
        display: block;
        margin-bottom: 4px;
        font-size: 11px;
        line-height: 1.2;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        color: #8b8297;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary {
        font-size: 15px;
        font-weight: 700;
        color: #304A9A;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary .pill-chip,
    .data-table.mobile-card-table tbody td.mobile-cell--primary strong {
        font-size: 15px;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--amount {
        font-weight: 700;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .data-table.mobile-card-table tbody td.mobile-cell--amount .pill-chip {
        display: inline-flex;
        width: auto;
        max-width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action {
        margin-top: 4px;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action::before {
        margin-bottom: 8px;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action > *,
    .data-table.mobile-card-table tbody td.mobile-cell--action .action-cell,
    .data-table.mobile-card-table tbody td.mobile-cell--action form {
        width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action button.btn {
        width: 100%;
        justify-content: center;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action .order-actions-dropdown-toggle,
    .data-table.mobile-card-table tbody td.mobile-cell--action .actions-dropdown-toggle {
        width: 44px !important;
    }

    .data-table.mobile-card-table tbody td .actions-dropdown-menu {
        right: 0;
        left: auto;
    }

    .clients-table-search,
    .summary-orders-modal-search,
    .client-search-group,
    .filter-group {
        width: 100%;
        max-width: none;
    }

    .history-modal .modal-body,
    .large-modal .modal-body,
    .order-detail-modal-body,
    .client-results-modal-body {
        padding: 14px !important;
    }

.history-modal .modal-header,
.large-modal .modal-header {
        padding: 14px 14px 0 !important;
    }
}

@media (max-width: 1100px) {
    .search-history-modal-content .history-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 768px) {
    .mobile-fab-new-order {
        display: none !important;
    }
}

@media (max-width: 767px) {
    body {
        overflow-x: hidden;
    }

    .search-history-modal-content .history-filters {
        grid-template-columns: 1fr;
    }

    .search-history-modal-content .search-history-filter-actions .btn {
        width: 100%;
        min-width: 0;
    }

    main,
    .main-content,
    .page-content,
    .orders-page,
    .orders-content {
        max-width: 100%;
        overflow-x: hidden;
    }

    .card,
    .dashboard-card,
    .orders-card {
        max-width: 100%;
        overflow: hidden;
    }

    .orders-pending-desktop-table,
    .orders-total-desktop-table {
        display: none !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list {
        display: flex !important;
        flex-direction: column;
        gap: 12px;
        width: 100%;
    }

    .mobile-order-card {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 16px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
        overflow: hidden;
    }

    .mobile-order-card-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 10px;
    }

    .mobile-order-code {
        min-width: 0;
        font-size: 16px;
        font-weight: 700;
        color: #304A9A;
        line-height: 1.2;
        word-break: break-word;
    }

    .mobile-order-status {
        flex: 0 0 auto;
        padding: 5px 9px;
        border-radius: 999px;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        line-height: 1;
        white-space: nowrap;
    }

    .mobile-order-body {
        display: grid;
        gap: 6px;
    }

    .mobile-order-line {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        gap: 12px;
        font-size: 13px;
        line-height: 1.3;
    }

    .mobile-order-label {
        color: #7B7188;
        flex: 0 0 auto;
    }

    .mobile-order-value {
        color: #2F3260;
        font-weight: 700;
        text-align: right;
        word-break: break-word;
        min-width: 0;
    }

    .mobile-order-value .pill-chip {
        max-width: 100%;
    }

    .mobile-order-actions {
        margin-top: 12px;
    }

    .mobile-order-actions .btn,
    .mobile-order-actions button,
    .mobile-order-actions a {
        width: 100%;
        min-height: 40px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }

    .orders-total-mobile-list .mobile-order-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07);
        overflow: hidden;
        gap: 0;
    }

    .orders-total-mobile-list .mobile-order-header,
    .orders-total-mobile-list .mobile-order-card-airy .mobile-order-card-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 0;
    }

    .orders-total-mobile-list .mobile-order-code {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
    }

    .orders-total-mobile-list .mobile-order-summary-topline,
    .orders-total-mobile-list .mobile-order-subline {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .orders-total-mobile-list .mobile-order-header-actions {
        display: flex;
        align-items: center;
        gap: 8px;
        flex: 0 0 auto;
    }

    .orders-total-mobile-list .mobile-status-pill,
    .orders-total-mobile-list .mobile-order-status {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 24px;
        padding: 5px 10px;
        border-radius: 999px;
        font-size: 11px;
        line-height: 1;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    .orders-total-mobile-list .mobile-order-client-box {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin: 12px 0;
        border-radius: 16px;
        background: #F4F3FF;
    }

    .orders-total-mobile-list .mobile-order-client-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .orders-total-mobile-list .mobile-order-client-info {
        min-width: 0;
        flex: 1;
    }

    .orders-total-mobile-list .mobile-order-client-info strong {
        display: block;
        font-size: 16px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    .orders-total-mobile-list .mobile-order-client-info span {
        display: block;
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    .orders-total-mobile-list .mobile-order-metrics-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
    }

    .orders-total-mobile-list .mobile-order-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    .orders-total-mobile-list .mobile-order-metric-icon {
        width: 28px;
        height: 28px;
        margin-bottom: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .orders-total-mobile-list .metric-total {
        background: #E8F1FF;
        color: #2563EB;
    }

    .orders-total-mobile-list .metric-debt {
        background: #FFF1D6;
        color: #F97316;
    }

    .orders-total-mobile-list .metric-payment {
        background: #E2FBEA;
        color: #16A34A;
    }

    .orders-total-mobile-list .mobile-order-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    .orders-total-mobile-list .mobile-order-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        color: #1F2A5A;
        font-weight: 600;
        word-break: break-word;
    }

    .orders-total-mobile-list .mobile-order-footer,
    .orders-total-mobile-list .mobile-order-actions {
        margin-top: 12px;
    }

    .orders-total-mobile-list .mobile-order-detail-btn {
        display: flex !important;
        width: 100% !important;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
    }

    .orders-pending-mobile-list .mobile-order-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07);
        overflow: hidden;
        gap: 0;
    }

    .orders-pending-mobile-list .mobile-order-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 0;
    }

    .orders-pending-mobile-list .mobile-order-card-airy .mobile-order-code {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
        white-space: normal;
        overflow: visible;
        text-overflow: unset;
    }

    .orders-pending-mobile-list .mobile-order-summary-topline,
    .orders-pending-mobile-list .mobile-order-subline {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .orders-pending-mobile-list .mobile-status-pill,
    .orders-pending-mobile-list .mobile-order-status {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 24px;
        padding: 5px 10px;
        border-radius: 999px;
        font-size: 11px;
        line-height: 1;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    .orders-pending-mobile-list .mobile-order-client-box {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin: 12px 0;
        border-radius: 16px;
        background: #F4F3FF;
    }

    .orders-pending-mobile-list .mobile-order-client-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .orders-pending-mobile-list .mobile-order-client-info {
        min-width: 0;
        flex: 1;
    }

    .orders-pending-mobile-list .mobile-order-client-info strong {
        display: block;
        font-size: 16px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    .orders-pending-mobile-list .mobile-order-client-info span {
        display: block;
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    .orders-pending-mobile-list .mobile-order-metrics-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
    }

    .orders-pending-mobile-list .mobile-order-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    .orders-pending-mobile-list .mobile-order-metric-icon {
        width: 28px;
        height: 28px;
        margin-bottom: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .orders-pending-mobile-list .metric-total {
        background: #E8F1FF;
        color: #2563EB;
    }

    .orders-pending-mobile-list .metric-debt {
        background: #FFF1D6;
        color: #F97316;
    }

    .orders-pending-mobile-list .metric-debt-paid,
    .orders-pending-mobile-list .metric-payment {
        background: #E2FBEA;
        color: #16A34A;
    }

    .orders-pending-mobile-list .metric-payment-pending {
        background: #FFF1D6;
        color: #F97316;
    }

    .orders-pending-mobile-list .mobile-order-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    .orders-pending-mobile-list .mobile-order-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        color: #1F2A5A;
        font-weight: 700;
        word-break: break-word;
    }

    .orders-pending-mobile-list .mobile-order-payment,
    .orders-pending-mobile-list .mobile-order-meta,
    .orders-pending-mobile-list .mobile-order-card-airy > .mobile-order-body:last-of-type,
    .orders-pending-mobile-list .mobile-order-subline {
        display: none !important;
    }

    .orders-pending-mobile-list .mobile-order-detail-btn,
    .orders-pending-mobile-list .mobile-order-actions .orders-detail-action-btn {
        display: flex !important;
        width: 100% !important;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        margin-top: 12px;
    }

    .orders-pending-mobile-list .mobile-order-card {
        border-radius: 18px;
        box-shadow: 0 6px 16px rgba(38, 55, 90, 0.07);
    }

    .orders-pending-mobile-list .mobile-order-card-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 10px;
    }

    .orders-pending-mobile-list .mobile-order-code {
        min-width: 0;
        font-size: 15px;
        line-height: 1.2;
        font-weight: 700;
        color: #304A9A;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .orders-pending-mobile-list .mobile-status-pill,
    .orders-pending-mobile-list .mobile-order-status {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 24px;
        padding: 5px 10px;
        border-radius: 999px;
        font-size: 11px;
        line-height: 1;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    .orders-pending-mobile-list .mobile-order-client {
        font-size: 18px;
        line-height: 1.2;
        font-weight: 700;
        color: #2F3260;
        margin-bottom: 4px;
    }

    .orders-pending-mobile-list .mobile-order-subline {
        font-size: 13px;
        line-height: 1.3;
        color: #776F86;
        margin-bottom: 12px;
    }

    .orders-pending-mobile-list .mobile-order-money-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin: 12px 0;
    }

    .orders-pending-mobile-list .mobile-money-box {
        padding: 10px 12px;
        border-radius: 14px;
        background: #F7F8FF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    .orders-pending-mobile-list .mobile-money-box span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #7B7188;
        margin-bottom: 4px;
    }

    .orders-pending-mobile-list .mobile-money-box strong {
        display: block;
        font-size: 16px;
        line-height: 1.1;
        color: #304A9A;
    }

    .orders-pending-mobile-list .mobile-money-box.is-debt {
        background: #FFF7EA;
    }

    .orders-pending-mobile-list .mobile-money-box.is-debt strong {
        color: #A85B00;
    }

    .orders-pending-mobile-list .mobile-order-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        margin: 10px 0;
        font-size: 12px;
        line-height: 1.2;
        color: #7B7188;
    }

    .orders-pending-mobile-list .mobile-order-meta span {
        padding: 5px 8px;
        border-radius: 999px;
        background: #F4F5FB;
    }

    .orders-pending-mobile-list .mobile-order-payment {
        margin: 8px 0 12px;
    }

    .orders-pending-mobile-list .mobile-order-body,
    .orders-pending-mobile-list .mobile-order-summary-topline {
        display: none;
    }

    .orders-pending-mobile-list .mobile-order-actions {
        margin-top: 0;
    }

    .orders-pending-mobile-list .mobile-order-actions .btn,
    .orders-pending-mobile-list .mobile-order-actions a,
    .orders-pending-mobile-list .mobile-order-actions button {
        display: flex;
        width: 100%;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }
}

@media (max-width: 767px) {
    html,
    body {
        height: auto !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        scroll-behavior: auto !important;
    }

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
    }

    main,
    .main-content,
    .page-content,
    .app-content,
    .dashboard-content,
    .content-area,
    .content-wrapper,
    .dashboard-wrapper,
    .dashboard-layout,
    .dashboard-page {
        height: auto !important;
        min-height: auto !important;
        overflow: visible !important;
        overflow-y: visible !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch;
    }

    .mobile-page-header {
        position: static !important;
        top: auto !important;
        background: rgba(255, 255, 255, 0.96) !important;
        transition: transform 0.18s ease, opacity 0.18s ease !important;
        transform: translateZ(0);
        will-change: transform;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .mobile-page-header .header-main-button,
    .mobile-page-header .mobile-primary-cta-shell {
        display: block !important;
        grid-area: cta !important;
        width: 100% !important;
    }

    .mobile-page-header .header-main-button .btn,
    .mobile-page-header .header-main-button > a.btn,
    .mobile-page-header .header-main-button > button.btn,
    .mobile-page-header .mobile-primary-cta,
    .mobile-page-header .btn-nueva-orden {
        display: inline-flex !important;
        width: 100% !important;
        justify-content: center !important;
    }

    .mobile-page-header.is-collapsed {
        transform: translateY(0);
        padding: 14px !important;
        min-height: auto !important;
        border-radius: 18px !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .mobile-page-header,
    .bottom-nav,
    .mobile-bottom-nav,
    .bottom-menu,
    .card,
    .dashboard-card,
    .mobile-card {
        transition-property: transform, opacity, background-color, border-color !important;
    }

    .bottom-nav,
    .mobile-bottom-nav,
    .bottom-menu {
        position: fixed;
        background: rgba(255, 255, 255, 0.98) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .mobile-fab-new-order {
        bottom: calc(
            var(--mobile-nav-height) +
            42px +
            env(safe-area-inset-bottom, 0px)
        ) !important;
        background: rgba(74, 91, 168, 0.98) !important;
        transform: translateZ(0);
        will-change: transform, opacity;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
        display: none !important;
    }

    .card,
    .dashboard-card,
    .mobile-card,
    .mobile-order-card,
    .quick-card,
    .info-card {
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
    }

    .table-card-header.card-header-row,
    .general-summary-card-actions,
    .third-party-action-area,
    .delayed-orders-actions {
        width: 100%;
    }

    .orders-secondary-action-btn,
    .dashboard-card-primary-action,
    .general-summary-card-actions .btn,
    .third-party-action-area .btn,
    .delayed-orders-actions .btn {
        display: inline-flex !important;
        width: 100% !important;
        justify-content: center !important;
    }

    .notifications-shell,
    .notifications-dropdown,
    .table-wrapper,
    .table-scroll-area {
        -webkit-overflow-scrolling: touch;
    }
}

@media (max-width: 767px) and (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}

@media (max-width: 767px) {
    .orders-filter-row,
    .mobile-filter-row,
    .filter-inline-row {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-end !important;
        gap: 10px !important;
        width: 100% !important;
        flex-wrap: nowrap !important;
    }

    .orders-filter-field,
    .mobile-filter-field,
    .filter-field {
        flex: 1 1 auto !important;
        min-width: 0 !important;
    }

    .orders-filter-field select,
    .mobile-filter-field select,
    .filter-field select {
        width: 100% !important;
    }

    .orders-filter-button,
    .mobile-filter-button,
    .filter-button {
        width: 44px !important;
        height: 44px !important;
        min-width: 44px !important;
        min-height: 44px !important;
        flex: 0 0 44px !important;
        border-radius: 12px !important;
        border: 1px solid rgba(190, 220, 230, 0.9) !important;
        background: #fff !important;
        color: #5AA6B8 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0 !important;
    }

    .register-order-card,
    .order-entry-card,
    .page-section,
    .content-area {
        overflow: visible !important;
    }

    .actions-dropdown,
    .more-actions-wrapper,
    .mobile-more-actions,
    .actions-dropdown-wrapper {
        position: relative !important;
        z-index: 1200 !important;
        overflow: visible !important;
    }

    .actions-dropdown-menu,
    .more-actions-menu,
    .mobile-more-actions-menu,
    .actions-dropdown-wrapper .actions-dropdown-menu {
        position: absolute !important;
        top: calc(100% + 6px) !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 1300 !important;
        min-width: 0 !important;
        background: #fff !important;
        border-radius: 14px !important;
        border: 1px solid rgba(190, 220, 230, 0.9) !important;
        box-shadow: 0 12px 28px rgba(38, 55, 90, 0.18) !important;
        overflow: hidden !important;
    }

    .register-order-card.dropdown-open,
    .order-entry-card.dropdown-open {
        position: relative !important;
        z-index: 1100 !important;
        overflow: visible !important;
    }

    .client-data-card,
    .dashboard-card,
    .info-card {
        position: relative;
        z-index: 1;
    }

    .total-orders-section .mobile-view-all-button {
        margin-bottom: 16px !important;
    }

    .modal-dialog.all-orders-modal-content,
    .all-orders-modal-content {
        height: 88vh !important;
        max-height: 88vh !important;
        min-height: 0 !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }

    .all-orders-modal-content > .modal-header,
    .all-orders-modal-content > .all-orders-modal-header {
        flex: 0 0 auto !important;
    }

    .all-orders-modal-content > .modal-body,
    .all-orders-modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 12px !important;
    }

    .all-orders-mobile-results {
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        padding-bottom: 0 !important;
        margin-bottom: 0 !important;
        overflow: visible !important;
    }

    .all-orders-mobile-results > *:last-child {
        margin-bottom: 0 !important;
    }

    #allOrdersModal,
    .all-orders-modal-overlay {
        z-index: 2000 !important;
        align-items: flex-end !important;
        justify-content: center !important;
        padding: 8px !important;
    }

    #allOrdersModal .all-orders-modal,
    #allOrdersModal .all-orders-modal-content,
    #allOrdersModal .modal-orders-wide {
        position: relative !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        top: auto !important;
        width: 100% !important;
        max-width: none !important;
        height: min(88vh, 760px) !important;
        max-height: 88vh !important;
        margin: 0 !important;
        border-radius: 24px 24px 18px 18px !important;
        overflow: hidden !important;
        background: #fff !important;
        display: flex !important;
        flex-direction: column !important;
        z-index: 2001 !important;
    }

    #allOrdersModal .all-orders-modal-header,
    #allOrdersModal .modal-header {
        flex: 0 0 auto;
        position: sticky;
        top: 0;
        z-index: 5;
        background: #fff;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 16px 16px 10px !important;
        border-bottom: 1px solid rgba(210, 225, 235, 0.7);
    }

    #allOrdersModal .all-orders-modal-header h3,
    #allOrdersModal .all-orders-modal-title {
        margin: 0;
        font-size: 18px;
        line-height: 1.2;
        font-weight: 700;
        color: #304A9A;
    }

    #allOrdersModal .all-orders-modal-close,
    #allOrdersModal .modal-close-btn {
        width: 40px;
        height: 40px;
        min-height: 40px;
        border-radius: 999px;
        border: 0;
        background: #F4F5FB;
        color: #111827;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        padding: 0;
    }

    #allOrdersModal .all-orders-modal-body,
    #allOrdersModal .modal-body {
        flex: 1 1 auto;
        min-height: 0;
        height: auto !important;
        max-height: none !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch;
        padding: 12px 16px 18px !important;
        display: block !important;
    }

    #allOrdersModal .all-orders-filter-form,
    #allOrdersModal .orders-total-filters {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
        margin-bottom: 14px !important;
    }

    #allOrdersModal .orders-filter-search {
        grid-column: 1 / -1 !important;
    }

    #allOrdersModal .orders-filter-actions {
        grid-column: 1 / -1 !important;
        display: block !important;
    }

    #allOrdersModal .all-orders-filter-form label,
    #allOrdersModal .orders-total-filters label {
        display: block;
        margin-bottom: 5px;
        font-size: 11px;
        line-height: 1.1;
        font-weight: 700;
        color: #8B82A0;
    }

    #allOrdersModal .all-orders-filter-form input,
    #allOrdersModal .all-orders-filter-form select,
    #allOrdersModal .orders-total-filters input,
    #allOrdersModal .orders-total-filters select {
        width: 100%;
        min-height: 42px;
        border-radius: 12px;
        font-size: 13px;
        padding: 9px 12px;
        box-sizing: border-box;
    }

    #allOrdersModal .orders-filter-actions .btn {
        width: 100% !important;
        min-width: 0 !important;
        margin-left: 0 !important;
    }

    #allOrdersModal .modal-search-autocomplete {
        position: relative;
        overflow: visible !important;
        z-index: 30;
    }

    #allOrdersModal .modal-smart-search-input {
        width: 100%;
    }

    #allOrdersModal .modal-search-suggestions {
        position: absolute;
        top: calc(100% + 6px);
        left: 0;
        right: 0;
        z-index: 9999;
        max-height: 220px;
        overflow-y: auto;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.95);
        border-radius: 14px;
        box-shadow: 0 10px 24px rgba(38, 55, 90, 0.16);
        padding: 6px;
    }

    #allOrdersModal .modal-search-suggestion-item {
        width: 100%;
        border: 0;
        background: transparent;
        padding: 10px 12px;
        border-radius: 10px;
        text-align: left;
        display: grid;
        gap: 2px;
    }

    #allOrdersModal .modal-search-suggestion-item:active,
    #allOrdersModal .modal-search-suggestion-item:hover {
        background: #F4F3FF;
    }

    #allOrdersModal .modal-search-suggestion-title {
        font-size: 13px;
        font-weight: 700;
        color: #304A9A;
    }

    #allOrdersModal .modal-search-suggestion-meta {
        font-size: 12px;
        color: #6F6A7F;
    }

    #allOrdersModal .all-orders-desktop-results,
    #allOrdersModal .orders-total-table-shell,
    .all-orders-modal-content table,
    .all-orders-modal-content .desktop-table,
    .all-orders-modal-content .desktop-results,
    .all-orders-modal-content .bottom-spacer,
    .all-orders-modal-content .mobile-spacer,
    .all-orders-modal-content .footer-spacer,
    #allOrdersModal .orders-total-table-shell table,
    #allOrdersModal .orders-total-table-shell thead,
    #allOrdersModal .orders-total-table-shell tbody {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        flex: 0 0 0 !important;
    }

    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
        min-height: 0 !important;
        height: auto !important;
        padding: 0 0 12px !important;
        margin-bottom: 0 !important;
        overflow: visible !important;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-card-airy,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07);
        overflow: hidden;
        gap: 0;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-header,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 0;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-code,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-code {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-subline,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-subline {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-status-pill,
    #allOrdersModal .orders-modal-results-mobile .mobile-status-pill {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 24px;
        padding: 5px 10px;
        border-radius: 999px;
        font-size: 11px;
        line-height: 1;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-client-box,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-box {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin: 12px 0;
        border-radius: 16px;
        background: #F4F3FF;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-client-icon,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-client-info,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info {
        min-width: 0;
        flex: 1;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-client-info strong,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info strong {
        display: block;
        font-size: 16px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-client-info span,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info span {
        display: block;
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-metrics-grid,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metrics-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-metric,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-metric-icon,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric-icon {
        width: 28px;
        height: 28px;
        margin-bottom: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    #allOrdersModal .all-orders-mobile-results .metric-total,
    #allOrdersModal .orders-modal-results-mobile .metric-total {
        background: #E8F1FF;
        color: #2563EB;
    }

    #allOrdersModal .all-orders-mobile-results .metric-debt,
    #allOrdersModal .orders-modal-results-mobile .metric-debt {
        background: #FFF1D6;
        color: #F97316;
    }

    #allOrdersModal .all-orders-mobile-results .metric-payment,
    #allOrdersModal .orders-modal-results-mobile .metric-payment {
        background: #E2FBEA;
        color: #16A34A;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-metric span,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-metric strong,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        color: #1F2A5A;
        font-weight: 700;
        word-break: break-word;
    }

    #allOrdersModal .all-orders-mobile-results .mobile-order-detail-btn,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-detail-btn {
        display: flex !important;
        width: 100% !important;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        background: #4A5BA8;
        color: #fff;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
    }

    #allOrdersModal .all-orders-modal-body::after,
    #allOrdersModal .modal-body::after,
    .all-orders-modal-body::after,
    #allOrdersModal .all-orders-mobile-results::after,
    #allOrdersModal .orders-modal-results-mobile::after,
    .all-orders-mobile-results::after {
        display: none !important;
        content: none !important;
        height: 0 !important;
    }

    #allOrdersModal .all-orders-modal-body > .all-orders-desktop-results,
    #allOrdersModal .all-orders-modal-body > .orders-total-table-shell {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        flex: 0 0 0 !important;
    }

    .all-orders-modal-content .history-empty-state {
        margin: 0 !important;
        padding: 0 !important;
        min-height: 0 !important;
    }

    #otherPendingOrdersModal,
    .other-pending-orders-modal-overlay {
        z-index: 2000 !important;
        align-items: flex-end !important;
        justify-content: center !important;
        padding: 8px !important;
    }

    #otherPendingOrdersModal .modal-dialog,
    #otherPendingOrdersModal .pending-orders-modal,
    #otherPendingOrdersModal .pending-orders-modal-content {
        position: relative !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        top: auto !important;
        width: 100% !important;
        max-width: none !important;
        height: 88vh !important;
        max-height: 88vh !important;
        min-height: 0 !important;
        margin: 0 !important;
        border-radius: 24px 24px 18px 18px !important;
        overflow: hidden !important;
        background: #fff !important;
        display: flex !important;
        flex-direction: column !important;
        z-index: 2001 !important;
    }

    #otherPendingOrdersModal .modal-header,
    #otherPendingOrdersModal .pending-orders-modal-header {
        flex: 0 0 auto !important;
        position: sticky;
        top: 0;
        z-index: 5;
        background: #fff;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 16px 16px 10px !important;
        border-bottom: 1px solid rgba(210, 225, 235, 0.7);
    }

    #otherPendingOrdersModal .modal-header h3,
    #otherPendingOrdersModal .pending-orders-modal-title {
        margin: 0;
        font-size: 18px;
        line-height: 1.2;
        font-weight: 700;
        color: #304A9A;
    }

    #otherPendingOrdersModal .modal-close-btn,
    #otherPendingOrdersModal .pending-orders-modal-close {
        width: 40px;
        height: 40px;
        min-height: 40px;
        border-radius: 999px;
        border: 0;
        background: #F4F5FB;
        color: #111827;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        padding: 0;
    }

    #otherPendingOrdersModal .modal-body,
    #otherPendingOrdersModal .pending-orders-modal-body,
    #otherPendingOrdersModal .delayed-orders-modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: touch;
        padding: 12px 16px 18px !important;
        display: block !important;
    }

    #otherPendingOrdersModal .pending-orders-filter-form,
    #otherPendingOrdersModal .pending-other-filters,
    #otherPendingOrdersModal .modal-filter-form {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin-bottom: 14px !important;
    }

    #otherPendingOrdersModal .filter-search,
    #otherPendingOrdersModal .modal-search-autocomplete,
    #otherPendingOrdersModal .pending-other-filter-search {
        grid-column: 1 / -1;
    }

    #otherPendingOrdersModal .filter-full,
    #otherPendingOrdersModal .filter-laundry,
    #otherPendingOrdersModal .pending-other-filter-laundry {
        grid-column: 1 / -1;
    }

    #otherPendingOrdersModal label {
        display: block;
        margin-bottom: 5px;
        font-size: 11px;
        line-height: 1.1;
        font-weight: 700;
        color: #8B82A0;
    }

    #otherPendingOrdersModal input,
    #otherPendingOrdersModal select {
        width: 100%;
        min-height: 42px;
        border-radius: 12px;
        font-size: 13px;
        padding: 9px 12px;
        box-sizing: border-box;
    }

    #otherPendingOrdersModal .pending-other-filter-actions,
    #otherPendingOrdersModal .pending-orders-clear-btn {
        grid-column: 1 / -1;
    }

    #otherPendingOrdersModal .clear-filters-btn,
    #otherPendingOrdersModal .pending-orders-clear-btn {
        width: 100%;
        min-height: 48px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
        margin-bottom: 16px !important;
    }

    #otherPendingOrdersModal .modal-search-autocomplete {
        position: relative;
        overflow: visible !important;
        z-index: 30;
    }

    #otherPendingOrdersModal .modal-search-suggestions {
        position: absolute;
        top: calc(100% + 6px);
        left: 0;
        right: 0;
        z-index: 9999;
        max-height: 220px;
        overflow-y: auto;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.95);
        border-radius: 14px;
        box-shadow: 0 10px 24px rgba(38, 55, 90, 0.16);
        padding: 6px;
    }

    #otherPendingOrdersModal .modal-search-suggestion-item {
        width: 100%;
        border: 0;
        background: transparent;
        padding: 10px 12px;
        border-radius: 10px;
        text-align: left;
        display: grid;
        gap: 2px;
    }

    #otherPendingOrdersModal .modal-search-suggestion-item:active,
    #otherPendingOrdersModal .modal-search-suggestion-item:hover {
        background: #F4F3FF;
    }

    #otherPendingOrdersModal .modal-search-suggestion-title {
        font-size: 13px;
        font-weight: 700;
        color: #304A9A;
    }

    #otherPendingOrdersModal .modal-search-suggestion-meta {
        font-size: 12px;
        color: #6F6A7F;
    }

    #otherPendingOrdersModal table,
    #otherPendingOrdersModal .pending-orders-desktop-results,
    #otherPendingOrdersModal .desktop-table,
    #otherPendingOrdersModal .desktop-results,
    #otherPendingOrdersModal .delayed-orders-table-shell {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
        flex: 0 0 0 !important;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
        min-height: 0 !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 0 12px !important;
        overflow: visible !important;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results[style] {
        display: flex !important;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results > :last-child {
        margin-bottom: 0 !important;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07);
        overflow: hidden;
        gap: 0;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 0;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-code {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-subline {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-box {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin: 12px 0;
        border-radius: 16px;
        background: #F4F3FF;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info {
        min-width: 0;
        flex: 1;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info strong {
        display: block;
        font-size: 16px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info span {
        display: block;
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metrics-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric-icon {
        width: 28px;
        height: 28px;
        margin-bottom: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        color: #1F2A5A;
        font-weight: 700;
        word-break: break-word;
    }

    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-detail-btn {
        display: flex !important;
        width: 100% !important;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        background: #4A5BA8;
        color: #fff;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
    }

    #otherPendingOrdersModal .bottom-spacer,
    #otherPendingOrdersModal .mobile-spacer,
    #otherPendingOrdersModal .nav-spacer,
    #otherPendingOrdersModal .footer-spacer {
        display: none !important;
        height: 0 !important;
        min-height: 0 !important;
        max-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
    }

    #otherPendingOrdersModal .modal-body::after,
    #otherPendingOrdersModal .pending-orders-mobile-results::after {
        display: none !important;
        content: none !important;
        height: 0 !important;
    }

    #allOrdersModal .history-empty-state {
        flex: 0 0 auto;
        margin-top: 0;
    }
}

@media (max-width: 380px) {
    #allOrdersModal .all-orders-filter-form,
    #allOrdersModal .orders-total-filters {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 767px) {
    .register-order-card .actions-dropdown,
    .register-order-card .more-actions-wrapper,
    .register-order-card .mobile-more-actions,
    .register-order-card .actions-dropdown-wrapper {
        margin-bottom: 16px !important;
    }

    .register-order-card .client-search-group,
    .register-order-card .client-dni-field,
    .register-order-card .dni-field,
    .register-order-card .client-search-field {
        margin-top: 0 !important;
    }

    .order-services-card,
    .services-added-card,
    .order-services-section,
    .services-section-card,
    .mobile-services-section {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }

    .order-services-card .table-card-header {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    .order-services-card .order-services-header-actions,
    .order-services-card .services-added-header-actions {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    .order-services-card .order-services-header-actions .btn,
    .order-services-card .add-service-btn,
    .order-services-card .mobile-add-service-btn,
    .order-services-card .btn-add-service {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        min-height: 44px !important;
        margin: 12px 0 14px !important;
        border-radius: 12px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        white-space: nowrap !important;
        transform: none !important;
    }

    .order-services-card .order-services-table,
    .order-services-card .services-table,
    .order-services-card .services-added-table,
    .order-services-card .table-scroll-area {
        display: none !important;
    }

    .mobile-services-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
    }

    .mobile-empty-services {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px dashed rgba(190, 220, 230, 0.95);
        color: #7B7188;
        font-size: 13px;
        line-height: 1.35;
        text-align: center;
    }

    .mobile-service-card {
        width: 100%;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        padding: 14px !important;
        border-radius: 16px !important;
        background: #fff !important;
        border: 1px solid rgba(190, 220, 230, 0.9) !important;
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.06) !important;
        overflow: hidden !important;
    }

    .mobile-service-card-top {
        width: 100% !important;
        min-width: 0 !important;
        display: grid !important;
        grid-template-columns: 32px minmax(0, 1fr) auto !important;
        gap: 8px !important;
        align-items: center !important;
        margin-bottom: 10px !important;
    }

    .mobile-service-icon {
        width: 32px;
        height: 32px;
        border-radius: 12px;
        background: #F4F3FF;
        color: #4A5BA8;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 14px;
        flex: 0 0 32px;
    }

    .mobile-service-card-top strong,
    .mobile-service-name {
        min-width: 0 !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
        font-size: 15px;
        line-height: 1.2;
        font-weight: 700;
        color: #304A9A;
    }

    .mobile-service-card-top span,
    .mobile-service-subtotal {
        flex: 0 0 auto;
        max-width: 88px !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        font-size: 15px;
        line-height: 1.2;
        font-weight: 700;
        color: #2F3260;
        white-space: nowrap;
        text-align: right;
    }

    .mobile-service-card-detail {
        margin-bottom: 8px;
        font-size: 12px;
        line-height: 1.35;
        color: #7B7188;
    }

    .mobile-service-card-meta {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        width: 100% !important;
        min-width: 0 !important;
        margin-bottom: 10px;
    }

    .mobile-service-card-meta span {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        max-width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        padding: 5px 8px;
        border-radius: 999px;
        background: #F4F5FB;
        color: #6F6A7F;
        font-size: 12px;
        line-height: 1.2;
    }

    .mobile-service-card-meta span i {
        color: #4A5BA8;
        font-size: 11px;
    }

    .mobile-service-card-actions {
        display: grid !important;
        width: 100% !important;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
        gap: 8px !important;
    }

    .mobile-service-card-actions button,
    .mobile-service-card-actions a {
        width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        min-height: 38px !important;
        border-radius: 10px !important;
        font-size: 13px !important;
        font-weight: 700 !important;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
    }

    .service-picker-modal,
    .add-service-modal,
    .service-picker-modal-body,
    .service-picker-detail,
    .service-picker-layout,
    .service-picker-detail * {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .service-picker-modal,
    .add-service-modal,
    .service-picker-modal-body,
    .service-picker-detail {
        overflow-x: hidden !important;
    }

    .service-compound-section,
    .rug-list-section,
    .carpet-list-section,
    .duvet-list-section,
    .service-lines-section,
    .service-subitems-section {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
        overflow: hidden !important;
        padding: 14px !important;
        border-radius: 16px !important;
    }

    .service-compound-toolbar,
    .service-line-add-row,
    .rug-add-row,
    .carpet-add-row,
    .duvet-add-row {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        align-items: stretch !important;
    }

    .service-compound-toolbar > *,
    .service-compound-toolbar .btn,
    #service-size-group,
    #service-quantity-input,
    #service-price-input,
    .service-price-input-wrap,
    .service-line-add-row input,
    .service-line-add-row select,
    .rug-add-row input,
    .rug-add-row select,
    .carpet-add-row input,
    .carpet-add-row select,
    .duvet-add-row input,
    .duvet-add-row select {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
    }

    .service-compound-toolbar .btn,
    .service-line-add-row button,
    .rug-add-row button,
    .carpet-add-row button,
    .duvet-add-row button,
    .btn-add-service-line,
    .btn-add-rug-line,
    .btn-add-duvet-line,
    #service-compound-add-button {
        width: 100% !important;
        max-width: 100% !important;
        min-height: 42px !important;
        border-radius: 12px !important;
        box-sizing: border-box !important;
        white-space: nowrap !important;
        transform: none !important;
    }

    .service-compound-table,
    .rug-list-table,
    .carpet-list-table,
    .duvet-list-table,
    .service-lines-table,
    .service-subitems-table,
    .service-compound-table-shell {
        display: none !important;
    }

    .mobile-service-lines-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin-top: 12px !important;
    }

    .mobile-service-lines-empty {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px dashed rgba(190, 220, 230, 0.95);
        color: #7B7188;
        font-size: 13px;
        text-align: center;
    }

    .mobile-service-line-card {
        width: 100%;
        box-sizing: border-box;
        padding: 12px;
        border-radius: 14px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38,55,90,.06);
    }

    .mobile-service-line-top {
        display: flex;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 8px;
    }

    .mobile-service-line-top strong {
        min-width: 0;
        font-size: 14px;
        font-weight: 700;
        color: #304A9A;
    }

    .mobile-service-line-top span {
        flex: 0 0 auto;
        font-size: 13px;
        font-weight: 700;
        color: #2F3260;
    }

    .mobile-service-line-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    .mobile-service-line-meta span {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 5px 8px;
        border-radius: 999px;
        background: #F4F3FF;
        color: #6F6A7F;
        font-size: 12px;
        max-width: 100%;
    }

    .mobile-remove-line-btn {
        width: 100%;
        min-height: 36px;
        margin-top: 10px;
        border-radius: 10px;
        font-size: 13px;
        font-weight: 700;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
    }

    .service-total-card,
    .service-total-box,
    .modal-total-box,
    .rug-total-box,
    .duvet-total-box {
        width: 100% !important;
        box-sizing: border-box !important;
        margin-top: 14px !important;
        padding: 14px !important;
        border-radius: 16px !important;
    }

    .service-total-card .service-total-label,
    .service-total-box .total-label,
    .modal-total-box .total-label {
        font-size: 11px !important;
        letter-spacing: .04em;
        text-transform: uppercase;
    }

    .service-total-card strong,
    .service-total-box .total-value,
    .modal-total-box .total-value {
        font-size: 24px !important;
        line-height: 1 !important;
    }

    .service-picker-modal {
        width: calc(100vw - 16px) !important;
        max-width: calc(100vw - 16px) !important;
        max-height: calc(100vh - 16px) !important;
        height: calc(100vh - 16px) !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }

    .service-picker-modal-header {
        position: sticky;
        top: 0;
        z-index: 35;
        background: #fff;
        padding: 18px 18px 12px !important;
        border-bottom: 1px solid rgba(210, 225, 235, 0.7);
    }

    .service-picker-modal-header h3 {
        margin: 0;
        font-size: 24px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
    }

    .service-picker-modal-header .modal-close-btn {
        width: 42px;
        height: 42px;
        min-height: 42px;
        border-radius: 14px;
        background: #F5F5F7;
        color: #1F2A5A;
    }

    .service-picker-modal-body {
        display: flex !important;
        flex-direction: column !important;
        flex: 1 1 auto !important;
        min-height: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
    }

    .mobile-service-search {
        display: flex;
        align-items: center;
        gap: 10px;
        margin: 0 0px 12px;
        padding: 0 14px;
        min-height: 52px;
        border-radius: 16px;
        border: 1px solid rgba(190,220,230,.9);
        background: #fff;
        flex: 0 0 auto;
    }

    .mobile-service-search i {
        color: #7B86B7;
        font-size: 15px;
    }

    .mobile-service-search input {
        flex: 1 1 auto;
        min-width: 0;
        min-height: 0;
        padding: 3px;
        border: 0;
        background: transparent;
        outline: none;
        font-size: 15px;
        color: #2F3260;
    }

    .service-picker-layout {
        display: block !important;
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        padding: 0 12px 0px calc(16px + env(safe-area-inset-bottom, 0px)) !important;
        -webkit-overflow-scrolling: touch;
    }

    .mobile-service-step-selector,
    .mobile-service-step-form {
        display: none;
    }

    .mobile-service-step-selector.is-active,
    .mobile-service-step-form.is-active {
        display: block;
    }

    .service-picker-detail {
        padding: 0 !important;
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
    }

    .service-picker-detail-header {
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding: 14px;
        margin-bottom: 16px;
        border-radius: 18px;
        background: linear-gradient(180deg, #FFF5FA 0%, #FFF9FC 100%);
        border: 1px solid rgba(236, 164, 202, 0.45);
    }

    .service-picker-heading {
        align-items: center;
        gap: 12px;
    }

    .service-picker-icon {
        width: 52px;
        height: 52px;
        border-radius: 16px;
        background: #FFE4F1;
        color: #D7448C;
        font-size: 20px;
    }

    .service-picker-heading-copy {
        min-width: 0;
    }

    .service-picker-kicker {
        font-size: 11px;
        font-weight: 700;
        color: #B83B72;
        letter-spacing: .04em;
        text-transform: uppercase;
    }

    .service-picker-heading-main {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
    }

    .service-picker-detail-header h4 {
        font-size: 18px;
        line-height: 1.1;
        font-weight: 700;
        color: #304A9A;
    }

    .service-price-badge {
        min-height: 32px;
        padding: 6px 12px;
        border-radius: 999px;
        background: #fff;
        color: #D7448C;
        font-size: 13px;
        font-weight: 700;
        white-space: nowrap;
        border: 1px solid rgba(236, 164, 202, 0.45);
    }

    .service-picker-detail-header p {
        margin-top: 5px;
        font-size: 14px;
        line-height: 1.25;
        color: #6F6A7F;
    }

    .mobile-change-service-btn {
        width: 100%;
        min-height: 42px;
        border: none;
        border-radius: 12px;
        background: #fff;
        color: #D7448C;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        font-size: 14px;
        font-weight: 700;
    }

    .service-picker-form-grid {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
        margin-bottom: 18px;
    }

    .service-picker-sidebar {
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        max-height: none !important;
        overflow: visible !important;
    }

    .service-picker-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        overflow: visible !important;
        padding: 0 !important;
    }

    .mobile-service-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
    }

    .service-picker-item {
        width: 100%;
        min-width: 0 !important;
        padding: 14px !important;
        border-radius: 16px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(38,55,90,.06);
        scroll-snap-align: unset !important;
    }

    .service-picker-item.is-active {
        border-color: rgba(215, 68, 140, 0.35);
        box-shadow: 0 6px 18px rgba(215, 68, 140, 0.12);
        background: #FFF8FC;
    }

    .service-picker-item-icon {
        width: 44px;
        height: 44px;
        border-radius: 14px;
        background: #F4F3FF;
        color: #4A5BA8;
        font-size: 18px;
    }

    .service-picker-item-copy strong {
        font-size: 15px;
        line-height: 1.18;
        font-weight: 700;
        color: #304A9A;
    }

    .service-picker-item-copy span {
        margin-top: 4px;
        font-size: 13px;
        line-height: 1.25;
        color: #6F6A7F;
    }

    .service-picker-empty-state {
        padding: 14px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px dashed rgba(190, 220, 230, 0.95);
        color: #7B7188;
        font-size: 13px;
        text-align: center;
    }

    .service-picker-actions {
        position: sticky;
        bottom: 0;
        z-index: 30;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        margin-top: 18px;
        padding: 12px 0 calc(12px + env(safe-area-inset-bottom, 0px));
        background: linear-gradient(180deg, rgba(255,255,255,0) 0%, #fff 35%);
    }

    .service-picker-actions .btn {
        min-height: 50px;
        border-radius: 16px;
        font-size: 15px;
        font-weight: 700;
    }

    .modal-header,
    .mobile-modal-header,
    .service-modal-header,
    .orders-modal-header,
    .pending-orders-modal-header,
    .all-orders-modal-header,
    .service-picker-modal-header {
        min-height: 64px !important;
        padding: 14px 16px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 12px !important;
        background: #fff !important;
        border-bottom: 1px solid rgba(210,225,235,.75) !important;
        box-sizing: border-box !important;
    }

    .modal-header h2,
    .modal-header h3,
    .modal-title,
    .mobile-modal-title,
    .service-modal-header h2,
    .service-picker-modal-header h2,
    .service-picker-modal-header h3,
    .orders-modal-title,
    .pending-orders-modal-title,
    .all-orders-modal-title {
        margin: 0 !important;
        font-size: 20px !important;
        line-height: 1.15 !important;
        font-weight: 700 !important;
        color: #304A9A !important;
        min-width: 0 !important;
        flex: 1 1 auto !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
    }

    .modal-close,
    .btn-close,
    .mobile-close-btn,
    .modal-close-btn,
    .service-modal-close,
    .orders-modal-close,
    .pending-orders-modal-close,
    .all-orders-modal-close {
        width: 42px !important;
        height: 42px !important;
        min-width: 42px !important;
        min-height: 42px !important;
        flex: 0 0 42px !important;
        border: 0 !important;
        border-radius: 14px !important;
        background: #F5F5F7 !important;
        color: #1F2A5A !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 18px !important;
        line-height: 1 !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }

    .mobile-summary-orders-list,
    .summary-orders-mobile-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden] {
        display: flex !important;
    }

    .summary-orders-mobile-list .mobile-summary-order-card {
        position: relative;
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(38,55,90,.07);
        overflow: hidden;
    }

    .mobile-summary-order-top {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: flex-start;
        gap: 12px;
        margin-bottom: 10px;
    }

    .mobile-summary-order-main {
        min-width: 0;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .mobile-summary-order-side {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 8px;
        flex: 0 0 auto;
    }

    .mobile-order-code-pill {
        min-height: 30px;
        padding: 0 10px;
        border-radius: 999px;
        background: #F3F1FF;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
        font-weight: 700;
        color: #4A5BA8;
        white-space: nowrap;
    }

    .mobile-order-client {
        min-width: 0;
        font-size: 15px;
        line-height: 1.15;
        font-weight: 700;
        color: #1F2A5A;
        overflow-wrap: anywhere;
    }

    .mobile-order-status {
        min-height: 28px;
        padding: 0 10px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 11px;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    .mobile-order-status.pending {
        background: #FFF0C9;
        color: #A66300;
    }

    .mobile-order-status.cancelado,
    .mobile-order-status.done {
        background: #DDF7E7;
        color: #147A3F;
    }

    .mobile-summary-order-metrics {
        display: grid;
        grid-template-columns: repeat(3, minmax(0,1fr));
        gap: 8px;
    }

    .mobile-summary-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210,225,235,.75);
    }

    .mobile-summary-metric span {
        display: block;
        margin-bottom: 4px;
        font-size: 11px;
        line-height: 1;
        color: #7D7891;
    }

    .mobile-summary-metric strong {
        display: block;
        font-size: 13px;
        line-height: 1.15;
        font-weight: 700;
        color: #1F2A5A;
        overflow-wrap: anywhere;
    }

    .mobile-summary-metric.danger strong {
        color: #D91F11;
    }

    .mobile-summary-metric.success strong {
        color: #008A3D;
    }

    .mobile-payment-pill {
        min-height: 28px;
        padding: 0 10px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        font-size: 12px;
        font-weight: 700;
        background: #F1F2F7;
        color: #4A5BA8;
    }

    .mobile-payment-pill.yape {
        background: #EEE5FF;
        color: #6F2BD9;
    }

    .mobile-payment-pill.efectivo {
        background: #DDF7E7;
        color: #147A3F;
    }

    .mobile-payment-pill.plin {
        background: #DFF6F4;
        color: #0F766E;
    }

    .mobile-payment-pill.tarjeta {
        background: #E8F1FF;
        color: #2563EB;
    }

    .mobile-summary-order-bottom,
    .mobile-summary-detail-btn {
        display: none !important;
    }

    .payments-summary-section .table-wrapper,
    .payments-summary-section table,
    .payments-summary-section .summary-total-box--income,
    .summary-expenses-card .summary-expenses-list,
    .summary-expenses-card table,
    .summary-expenses-card .summary-total-box--expense,
    .payment-summary-table,
    .summary-payments-table,
    .daily-payments-table {
        display: none !important;
    }

    .mobile-payment-summary-list {
        display: flex;
        flex-direction: column;
        gap: 8px;
        width: 100%;
    }

    .mobile-payment-summary-list[hidden] {
        display: flex !important;
    }

    .mobile-payment-summary-card {
        width: 100%;
        min-height: 84px;
        padding: 14px;
        border-radius: 20px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(40,55,90,.06);
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 14px;
        box-sizing: border-box;
    }

    .mobile-payment-summary-left {
        display: flex;
        align-items: center;
        gap: 12px;
        min-width: 0;
    }

    .mobile-payment-icon {
        width: 52px;
        height: 52px;
        border-radius: 16px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 20px;
        flex-shrink: 0;
    }

    .mobile-payment-summary-card.efectivo .mobile-payment-icon {
        background: #E8F8EE;
        color: #15803D;
    }

    .mobile-payment-summary-card.yape .mobile-payment-icon {
        background: #F2E8FF;
        color: #7C3AED;
    }

    .mobile-payment-summary-card.plin .mobile-payment-icon {
        background: #DFF7F4;
        color: #0F766E;
    }

    .mobile-payment-summary-card.tarjeta .mobile-payment-icon {
        background: #F2F3F7;
        color: #4B5563;
    }

    .mobile-payment-info {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

    .mobile-payment-info small {
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    .mobile-payment-total {
        flex-shrink: 0;
        font-size: 24px;
        line-height: 1;
        font-weight: 700;
        color: #304A9A;
        text-align: right;
        margin-left: auto;
    }

    .mobile-payment-grand-total {
        margin-top: 16px;
        padding: 18px;
        border-radius: 22px;
        background: linear-gradient(180deg, #F5FFF8 0%, #F2FBF5 100%);
        border: 1px solid rgba(180,230,195,.9);
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
    }

    .mobile-payment-grand-total[hidden] {
        display: flex !important;
    }

    .mobile-expenses-list {
        display: flex;
        flex-direction: column;
        gap: 12px;
        width: 100%;
    }

    .mobile-expenses-list[hidden] {
        display: flex !important;
    }

    .summary-expenses-card .summary-empty-state {
        min-height: auto !important;
    }

    .mobile-expense-card {
        width: 100%;
        padding: 16px;
        border-radius: 22px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 6px 18px rgba(40,55,90,.06);
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 14px;
        box-sizing: border-box;
        overflow: hidden;
    }

    .mobile-expense-left {
        display: flex;
        align-items: center;
        gap: 14px;
        min-width: 0;
        flex: 1;
    }

    .mobile-expense-icon {
        width: 56px;
        height: 56px;
        border-radius: 18px;
        background: #F4EAFF;
        color: #7C3AED;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        font-size: 22px;
    }

    .mobile-expense-info {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 5px;
        flex: 1;
    }

    .mobile-expense-label {
        font-size: 11px;
        line-height: 1;
        text-transform: uppercase;
        color: #8B86A3;
    }

    .mobile-expense-title {
        font-size: 18px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mobile-expense-meta {
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    .mobile-expense-amount {
        flex-shrink: 0;
        font-size: 24px;
        line-height: 1;
        font-weight: 700;
        color: #304A9A;
        text-align: right;
        margin-left: auto;
        white-space: nowrap;
    }

    .mobile-expense-total-card {
        margin-top: 18px;
        padding: 18px;
        border-radius: 24px;
        background: linear-gradient(180deg, #FFF4F4 0%, #FFF8F8 100%);
        border: 1px solid rgba(255,190,190,.9);
        display: flex;
        align-items: center;
        gap: 16px;
    }

    .mobile-expense-total-card[hidden] {
        display: flex !important;
    }

    .mobile-expense-total-icon {
        width: 68px;
        height: 68px;
        border-radius: 22px;
        background: #FFE5E5;
        color: #D91F11;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        font-size: 28px;
    }

    .mobile-expense-total-info {
        display: flex;
        flex-direction: column;
        gap: 8px;
        min-width: 0;
    }

    .mobile-expense-total-info span {
        font-size: 16px;
        line-height: 1.2;
        font-weight: 700;
        color: #1F2A5A;
    }

    .mobile-expense-total-info strong {
        font-size: 52px;
        line-height: 1;
        font-weight: 700;
        color: #D91F11;
        overflow-wrap: anywhere;
    }

    .mobile-payment-grand-total span {
        font-size: 16px;
        line-height: 1.2;
        font-weight: 700;
        color: #166534;
    }

    .mobile-payment-grand-total strong {
        font-size: 34px;
        line-height: 1;
        font-weight: 700;
        color: #047857;
        margin-left: auto;
        text-align: right;
    }

    .third-party-section .table-wrapper,
    .third-party-section .table-scroll-area,
    .terceros-section .table-wrapper,
    .terceros-section .table-scroll-area,
    .expenses-section .table-wrapper,
    .expenses-section .table-scroll-area,
    .gastos-section .table-wrapper,
    .gastos-section .table-scroll-area,
    .closures-section .table-wrapper,
    .closures-section .table-scroll-area,
    .otros-cierres-section .table-wrapper,
    .otros-cierres-section .table-scroll-area,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-section .summary-orders-modal-table-shell,
    .resumen-section .summary-orders-modal-table-shell {
        display: none !important;
    }

    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .summary-orders-modal-body {
        padding-bottom: calc(72px + 24px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .third-party-mobile-list[hidden],
    .thirdparty-mobile-list[hidden],
    .terceros-mobile-list[hidden],
    .expenses-mobile-list[hidden],
    .gastos-mobile-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden] {
        display: flex !important;
    }

    .terceros-section,
    .third-party-section,
    .gastos-section,
    .expenses-section,
    .summary-section,
    .resumen-section {
        padding-bottom: calc(72px + 24px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .mobile-card-secondary-actions {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
        gap: 8px !important;
        margin-top: 12px !important;
    }

    .mobile-card-secondary-actions form,
    .mobile-card-secondary-actions .btn {
        width: 100% !important;
    }

    .third-party-mobile-list,
    .thirdparty-mobile-list,
    .terceros-mobile-list,
    .expenses-mobile-list,
    .gastos-mobile-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
    }

    .mobile-card-title-wrap {
        min-width: 0;
        flex: 1;
        display: flex;
        align-items: flex-start;
        gap: 10px;
    }

    .mobile-card-icon {
        width: 36px;
        height: 36px;
        flex: 0 0 36px;
        border-radius: 12px;
        background: #F4F3FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 15px;
    }

    .expense-icon {
        background: #F4F7FF;
        color: #304A9A;
    }

    .mobile-meta-pill,
    .mobile-status-pill,
    .mobile-method-pill {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        min-height: 26px;
        padding: 6px 9px;
        border-radius: 999px;
        background: #F4F5FB;
        color: #6F6A7F;
        font-size: 12px;
        line-height: 1;
        font-weight: 700;
    }

    .status-delivered {
        background: #DDFBEA;
        color: #167A45;
        text-transform: uppercase;
        font-size: 11px;
        font-weight: 700;
    }

    .status-pending {
        background: #FFF1C7;
        color: #9A5B00;
        text-transform: uppercase;
        font-size: 11px;
        font-weight: 700;
    }

    .mobile-card-action {
        display: flex;
        width: 100%;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        background: #4A5BA8;
        color: #fff;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
    }

    .mobile-secondary-action,
    .mobile-danger-action {
        width: 100% !important;
        min-height: 40px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        text-decoration: none;
        box-sizing: border-box;
    }

    .mobile-secondary-action {
        background: #fff;
        border: 1px solid rgba(74, 91, 168, 0.35);
        color: #4A5BA8;
    }

    .mobile-danger-action {
        background: #BF3D6B;
        border: 1px solid #BF3D6B;
        color: #fff;
    }

    .mobile-third-party-card,
    .mobile-thirdparty-card,
    .mobile-thirdparty-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38,55,90,0.07);
        overflow: hidden;
    }

    .mobile-third-party-card .mobile-card-top,
    .mobile-thirdparty-card .mobile-card-top,
    .mobile-thirdparty-card-airy .mobile-card-header,
    .mobile-thirdparty-card-airy .mobile-card-top {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 12px;
    }

    .mobile-third-party-card .mobile-card-title-wrap,
    .mobile-thirdparty-card .mobile-card-title-wrap {
        display: block;
        min-width: 0;
        flex: 1;
    }

    .mobile-third-party-card .mobile-card-icon,
    .mobile-thirdparty-card .mobile-card-icon {
        display: none;
    }

    .mobile-third-party-card .mobile-card-title,
    .mobile-thirdparty-card .mobile-card-title,
    .mobile-thirdparty-card-airy .mobile-card-title {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
    }

    .mobile-third-party-card .mobile-card-subtitle,
    .mobile-thirdparty-card .mobile-card-subtitle,
    .mobile-thirdparty-card-airy .mobile-card-subtitle {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .mobile-third-party-card .mobile-card-amount,
    .mobile-thirdparty-card .mobile-card-amount {
        display: none;
    }

    .mobile-third-party-card .mobile-card-meta,
    .mobile-thirdparty-card .mobile-card-meta {
        margin: 0 0 12px;
        gap: 8px;
    }

    .mobile-third-party-card .mobile-status-pill,
    .mobile-thirdparty-card .mobile-status-pill {
        order: -2;
    }

    .mobile-third-party-card .mobile-meta-pill,
    .mobile-thirdparty-card .mobile-meta-pill {
        position: relative;
        width: 100%;
        min-height: 68px;
        padding: 12px 12px 12px 68px;
        margin-bottom: 4px;
        border-radius: 16px;
        background: #F4F3FF;
        color: #2F3260;
        align-items: flex-start;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 2px;
        font-size: 0;
    }

    .mobile-third-party-card .mobile-meta-pill::before,
    .mobile-thirdparty-card .mobile-meta-pill::before {
        content: "\f2b5";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        position: absolute;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);
        width: 44px;
        height: 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .mobile-third-party-card .mobile-meta-pill i,
    .mobile-thirdparty-card .mobile-meta-pill i {
        display: none;
    }

    .mobile-third-party-card .mobile-meta-pill::after,
    .mobile-thirdparty-card .mobile-meta-pill::after {
        content: "Entrega programada";
        display: block;
        margin-bottom: 2px;
        font-size: 15px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    .mobile-third-party-card .mobile-meta-pill,
    .mobile-thirdparty-card .mobile-meta-pill {
        font-size: 12px;
        line-height: 1.25;
        color: #6F6A7F;
    }

    .mobile-third-party-card .mobile-card-action,
    .mobile-thirdparty-card .mobile-card-action {
        position: relative;
        margin-top: 0;
    }

    .mobile-third-party-card .mobile-card-top,
    .mobile-thirdparty-card .mobile-card-top,
    .mobile-thirdparty-card-airy .mobile-card-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 12px;
        position: static;
        padding-right: 0;
    }

    .mobile-third-party-card .mobile-card-top::after,
    .mobile-thirdparty-card .mobile-card-top::after,
    .mobile-third-party-card .mobile-card-action::before,
    .mobile-thirdparty-card .mobile-card-action::before,
    .mobile-third-party-card .mobile-card-action::after,
    .mobile-thirdparty-card .mobile-card-action::after {
        content: none !important;
        display: none !important;
    }

    .mobile-third-party-card .mobile-card-top .mobile-status-pill,
    .mobile-thirdparty-card .mobile-card-top .mobile-status-pill {
        position: static;
    }

    .mobile-third-party-card .mobile-card-title,
    .mobile-thirdparty-card .mobile-card-title,
    .mobile-thirdparty-card-airy .mobile-card-title,
    .mobile-third-party-card .mobile-thirdparty-main-box strong,
    .mobile-thirdparty-card .mobile-thirdparty-main-box strong,
    .mobile-thirdparty-card-airy .mobile-thirdparty-main-box strong,
    .mobile-third-party-card .mobile-card-action,
    .mobile-thirdparty-card .mobile-card-action,
    .mobile-thirdparty-card-airy .mobile-card-action {
        font-weight: 700 !important;
    }

    .mobile-third-party-card .mobile-card-amount,
    .mobile-thirdparty-card .mobile-card-amount {
        display: none;
    }

    .mobile-third-party-card .mobile-card-title-wrap,
    .mobile-thirdparty-card .mobile-card-title-wrap {
        display: block;
        min-width: 0;
        flex: 1;
    }

    .mobile-third-party-card .mobile-card-icon,
    .mobile-thirdparty-card .mobile-card-icon {
        display: none;
    }

    .mobile-third-party-card .mobile-meta-pill,
    .mobile-thirdparty-card .mobile-meta-pill {
        width: 100%;
        min-height: 68px;
        padding: 12px 12px 12px 68px;
        margin: 0;
        border-radius: 16px;
        background: #F4F3FF;
        position: relative;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: flex-start;
        gap: 2px;
        color: #6F6A7F;
        font-size: 12px;
        line-height: 1.25;
    }

    .mobile-third-party-card .mobile-meta-pill i,
    .mobile-thirdparty-card .mobile-meta-pill i {
        display: none;
    }

    .mobile-third-party-card .mobile-meta-pill::before,
    .mobile-thirdparty-card .mobile-meta-pill::before {
        content: "\f2b5";
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        position: absolute;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);
        width: 44px;
        height: 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .mobile-third-party-card .mobile-meta-pill::after,
    .mobile-thirdparty-card .mobile-meta-pill::after {
        content: "Entrega programada";
        display: block;
        margin-bottom: 2px;
        font-size: 15px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    .mobile-thirdparty-metrics-grid:empty,
    .mobile-thirdparty-metric:empty {
        display: none !important;
    }

    .mobile-third-party-card,
    .mobile-thirdparty-card {
        display: none !important;
    }

    .mobile-thirdparty-card-v1[hidden] {
        display: block !important;
    }

    .mobile-thirdparty-card-v1 {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(38,55,90,0.07);
        overflow: hidden;
    }

    .mobile-thirdparty-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 12px;
    }

    .mobile-thirdparty-title {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
    }

    .mobile-thirdparty-subtitle {
        margin-top: 4px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .mobile-thirdparty-highlight {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin-bottom: 12px;
        border-radius: 16px;
        background: #F4F3FF;
    }

    .mobile-thirdparty-highlight-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .mobile-thirdparty-highlight-content {
        min-width: 0;
    }

    .mobile-thirdparty-highlight-content span {
        display: block;
        font-size: 12px;
        line-height: 1.2;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    .mobile-thirdparty-highlight-content strong {
        display: block;
        font-size: 15px;
        line-height: 1.2;
        font-weight: 700;
        color: #2F3260;
        word-break: break-word;
    }

    .mobile-thirdparty-metrics {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        margin-bottom: 12px;
    }

    .mobile-thirdparty-metrics:empty {
        display: none !important;
    }

    .mobile-thirdparty-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210,225,235,.8);
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-thirdparty-metric:empty {
        display: none !important;
    }

    .metric-icon {
        width: 32px;
        height: 32px;
        flex: 0 0 32px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .metric-blue {
        background: #E8F1FF;
        color: #2563EB;
    }

    .metric-green {
        background: #E2FBEA;
        color: #16A34A;
    }

    .mobile-thirdparty-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 3px;
    }

    .mobile-thirdparty-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        font-weight: 700;
        color: #1F2A5A;
        word-break: break-word;
    }

    .mobile-thirdparty-action {
        display: flex;
        width: 100%;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        background: #4A5BA8;
        color: #fff;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
    }

    .mobile-expense-card {
        display: none !important;
    }

    .mobile-expense-card-v2 {
        display: none !important;
    }

    .mobile-expense-card-v3[hidden] {
        display: block !important;
    }

    .mobile-expense-card-v2 {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(38,55,90,.07);
        overflow: hidden;
    }

    .mobile-expense-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 12px;
        margin-bottom: 12px;
    }

    .mobile-expense-title-wrap {
        min-width: 0;
        flex: 1;
        display: flex;
        align-items: flex-start;
        gap: 12px;
    }

    .mobile-expense-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #F4F3FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .mobile-expense-title {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
    }

    .mobile-expense-subtitle {
        margin-top: 4px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .mobile-expense-amount-pill {
        flex: 0 0 auto;
        min-height: 40px;
        padding: 0 14px;
        border-radius: 14px;
        background: #FCE7F1;
        color: #B83B72;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 15px;
        line-height: 1;
        font-weight: 700;
        white-space: nowrap;
    }

    .mobile-expense-meta-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        margin-bottom: 12px;
    }

    .mobile-expense-meta-box {
        min-width: 0;
        padding: 12px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210,225,235,.8);
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .meta-icon {
        width: 32px;
        height: 32px;
        flex: 0 0 32px;
        border-radius: 999px;
        background: #EEF2FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .mobile-expense-meta-box span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 3px;
    }

    .mobile-expense-meta-box strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        font-weight: 700;
        color: #1F2A5A;
        word-break: break-word;
    }

    .mobile-expense-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .mobile-expense-actions form {
        width: 100%;
    }

    .mobile-expense-edit,
    .mobile-expense-delete {
        width: 100%;
        min-height: 42px;
        border-radius: 12px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
        box-sizing: border-box;
    }

    .mobile-expense-edit {
        background: #fff;
        border: 1px solid rgba(74,91,168,.35);
        color: #4A5BA8;
    }

    .mobile-expense-delete {
        background: #BF3D6B;
        border: 1px solid #BF3D6B;
        color: #fff;
    }

    .mobile-expense-card-v3 {
        width: 100%;
        box-sizing: border-box;
        padding: 14px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190,220,230,.9);
        box-shadow: 0 4px 12px rgba(38,55,90,.07);
        overflow: hidden;
    }

    .mobile-expense-card-v3 .mobile-expense-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 12px;
        margin-bottom: 12px;
    }

    .mobile-expense-card-v3 .mobile-expense-title-wrap {
        min-width: 0;
        flex: 1;
        display: grid;
        grid-template-columns: 44px minmax(0, 1fr);
        gap: 12px;
        align-items: center;
    }

    .mobile-expense-card-v3 .mobile-expense-icon {
        width: 44px;
        height: 44px;
        border-radius: 14px;
        background: #F4F3FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .mobile-expense-card-v3 .mobile-expense-main-text {
        min-width: 0;
    }

    .mobile-expense-card-v3 .mobile-expense-title {
        font-size: 15px;
        line-height: 1.18;
        font-weight: 700;
        color: #304A9A;
        word-break: normal;
        overflow-wrap: anywhere;
    }

    .mobile-expense-card-v3 .mobile-expense-subtitle {
        margin-top: 4px;
        font-size: 12px;
        line-height: 1.25;
        color: #6F6A7F;
    }

    .mobile-expense-card-v3 .mobile-expense-amount-pill {
        flex: 0 0 auto;
        min-height: 38px;
        padding: 0 14px;
        border-radius: 14px;
        background: #FCE7F1;
        color: #B83B72;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 15px;
        line-height: 1;
        font-weight: 700;
        white-space: nowrap;
    }

    .mobile-expense-card-v3 .mobile-expense-single-meta {
        margin-bottom: 12px;
    }

    .mobile-expense-card-v3 .mobile-expense-single-meta .mobile-expense-meta-box {
        width: 100%;
        min-width: 0;
        padding: 12px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210,225,235,.8);
        display: grid;
        grid-template-columns: 32px minmax(0, 1fr);
        align-items: center;
        gap: 10px;
    }

    .mobile-expense-card-v3 .meta-icon {
        width: 32px;
        height: 32px;
        border-radius: 999px;
        background: #EEF2FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .mobile-expense-card-v3 .meta-icon-pink {
        background: #FCE7F1;
        color: #B83B72;
    }

    .mobile-expense-card-v3 .mobile-expense-meta-box span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 3px;
    }

    .mobile-expense-card-v3 .mobile-expense-meta-box strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        font-weight: 700;
        color: #1F2A5A;
        overflow-wrap: anywhere;
    }

    .mobile-expense-card-v3 .mobile-expense-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .mobile-expense-card-v3 .mobile-expense-actions form {
        width: 100%;
    }

    .mobile-expense-card-v3 .mobile-expense-edit,
    .mobile-expense-card-v3 .mobile-expense-delete {
        width: 100%;
        min-height: 42px;
        border-radius: 12px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        font-size: 14px;
        font-weight: 700;
        text-decoration: none;
        box-sizing: border-box;
    }

    .mobile-expense-card-v3 .mobile-expense-edit {
        background: #fff;
        border: 1px solid rgba(74,91,168,.35);
        color: #4A5BA8;
    }

    .mobile-expense-card-v3 .mobile-expense-delete {
        background: #BF3D6B;
        border: 1px solid #BF3D6B;
        color: #fff;
    }

    .third-party-section .mobile-data-card,
    .terceros-section .mobile-data-card,
    .expenses-section .mobile-data-card,
    .gastos-section .mobile-data-card,
    .closures-section .mobile-data-card,
    .otros-cierres-section .mobile-data-card,
    .summary-section .mobile-data-card,
    .resumen-section .mobile-data-card {
        width: 100%;
        box-sizing: border-box;
        padding: 14px 16px !important;
        border-radius: 18px !important;
        background: #fff !important;
        border: 1px solid rgba(190, 220, 230, 0.9) !important;
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07) !important;
        overflow: hidden !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td,
    .terceros-section .data-table.mobile-card-table tbody td,
    .expenses-section .data-table.mobile-card-table tbody td,
    .gastos-section .data-table.mobile-card-table tbody td,
    .closures-section .data-table.mobile-card-table tbody td,
    .otros-cierres-section .data-table.mobile-card-table tbody td,
    .summary-section .data-table.mobile-card-table tbody td,
    .resumen-section .data-table.mobile-card-table tbody td {
        margin-bottom: 10px !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--primary,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--primary {
        font-size: 16px !important;
        line-height: 1.2 !important;
        font-weight: 700 !important;
        color: #304A9A !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--meta,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--meta {
        font-size: 12px !important;
        line-height: 1.35 !important;
        color: #6F6A7F !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--amount {
        font-size: 17px !important;
        line-height: 1.1 !important;
        font-weight: 700 !important;
        color: #304A9A !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--status [class*="payment-method"],
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--status [class*="payment-method"],
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--status [class*="payment-method"] {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-height: 24px !important;
        padding: 5px 10px !important;
        border-radius: 999px !important;
        font-size: 11px !important;
        line-height: 1 !important;
        font-weight: 700 !important;
        white-space: nowrap !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--action .icon-btn {
        width: 44px !important;
        height: 44px !important;
        min-width: 44px !important;
        min-height: 44px !important;
    }

    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .third-party-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .terceros-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .expenses-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .gastos-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .closures-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .otros-cierres-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .summary-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .resumen-section .data-table.mobile-card-table tbody td.mobile-cell--action a.btn {
        display: inline-flex !important;
        width: 100% !important;
        min-height: 40px !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        border-radius: 12px !important;
        font-size: 14px !important;
        font-weight: 700 !important;
    }

    .summary-section .summary-balance-strip,
    .resumen-section .summary-balance-strip,
    .summary-section .summary-operational-kpis,
    .resumen-section .summary-operational-kpis {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .summary-section .summary-balance-box,
    .resumen-section .summary-balance-box,
    .summary-section .summary-operational-kpi,
    .resumen-section .summary-operational-kpi {
        padding: 14px !important;
        border-radius: 18px !important;
        background: #fff !important;
        border: 1px solid rgba(190,220,230,.9) !important;
        box-shadow: 0 4px 12px rgba(38,55,90,.07) !important;
    }

    .summary-balance-strip-card--active .summary-balance-strip {
        display: none !important;
    }

    .summary-balance-strip-card--active {
        padding: 18px !important;
    }

    .summary-balance-strip-card--active .summary-block-header {
        margin-bottom: 18px !important;
        padding-bottom: 14px;
        border-bottom: 1px solid rgba(210,225,235,.75);
    }

    .mobile-balance-card {
        width: 100%;
        padding: 0;
        border-radius: 0;
        background: transparent;
        border: 0;
        box-shadow: none;
        box-sizing: border-box;
    }

    .mobile-balance-card[hidden] {
        display: block !important;
    }

    .mobile-balance-header {
        display: none;
    }

    .mobile-balance-header h3 {
        margin: 0 0 6px;
        font-size: 24px;
        line-height: 1.1;
        font-weight: 700;
        color: #1F2A5A;
    }

    .mobile-balance-header p {
        margin: 0;
        font-size: 14px;
        line-height: 1.4;
        color: #6F6A7F;
    }

    .mobile-balance-list {
        display: flex;
        flex-direction: column;
        gap: 14px;
        margin-bottom: 18px;
    }

    .mobile-balance-row {
        width: 100%;
        min-height: 72px;
        padding: 0;
        border-radius: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        box-sizing: border-box;
    }

    .mobile-balance-row.success {
        background: transparent;
        border: 0;
        padding-bottom: 14px;
        border-bottom: 1px solid rgba(210,225,235,.75);
    }

    .mobile-balance-row.danger {
        background: transparent;
        border: 0;
        padding-bottom: 14px;
        border-bottom: 1px dashed rgba(190,200,220,.9);
    }

    .mobile-balance-row-left {
        display: flex;
        align-items: center;
        gap: 12px;
        min-width: 0;
        flex: 1;
    }

    .mobile-balance-icon {
        width: 8px;
        height: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
        font-size: 0;
    }

    .mobile-balance-row.success .mobile-balance-icon {
        background: #16A34A;
        color: transparent;
    }

    .mobile-balance-row.danger .mobile-balance-icon {
        background: #DC2626;
        color: transparent;
    }

    .mobile-balance-row span {
        font-size: 16px;
        line-height: 1.2;
        color: #1F2A5A;
    }

    .mobile-balance-row strong {
        flex-shrink: 0;
        font-size: 26px;
        line-height: 1;
        font-weight: 700;
        text-align: right;
        overflow-wrap: anywhere;
    }

    .mobile-balance-row.success strong {
        color: #15803D;
    }

    .mobile-balance-row.danger strong {
        color: #D91F11;
    }

    .mobile-balance-total-card {
        width: 100%;
        padding: 22px;
        border-radius: 24px;
        background: linear-gradient(180deg, #F8F8FF 0%, #F3F4FF 100%);
        border: 1px solid rgba(205,210,255,.9);
        display: flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        text-align: center;
    }

    .mobile-balance-total-icon {
        display: none;
    }

    .mobile-balance-total-content {
        display: flex;
        flex-direction: column;
        gap: 6px;
        min-width: 0;
        flex: 1;
        align-items: center;
    }

    .mobile-balance-total-content span {
        font-size: 16px;
        line-height: 1.1;
        color: #4B5675;
    }

    .mobile-balance-total-content strong {
        font-size: clamp(34px, 8vw, 54px);
        line-height: .95;
        font-weight: 700;
        color: #3046C9;
        overflow-wrap: anywhere;
    }

    .mobile-balance-total-content small {
        width: fit-content;
        min-height: 28px;
        padding: 0 12px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        font-size: 12px;
        font-weight: 700;
    }

    .mobile-balance-total-content small.is-positive {
        background: #E7F8EC;
        color: #15803D;
    }

    .mobile-balance-total-content small.is-negative {
        background: #FFE8E8;
        color: #D91F11;
    }

.mobile-empty-state,
    .third-party-section .helper-text,
    .terceros-section .helper-text,
    .expenses-section .helper-text,
    .gastos-section .helper-text,
    .closures-section .helper-text,
    .otros-cierres-section .helper-text {
        padding: 16px;
        border-radius: 16px;
        background: #F8FAFF;
        border: 1px dashed rgba(190,220,230,.95);
        text-align: center;
        color: #6F6A7F;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    html,
    body {
        overflow-x: hidden;
    }

    .dashboard-frame {
        padding: 16px;
        min-height: 100vh;
        min-height: 100dvh;
        height: auto;
        overflow: visible;
    }

    .dashboard-shell,
    .app-layout {
        display: block;
        min-height: calc(100vh - 32px);
        min-height: calc(100dvh - 32px);
        height: auto;
        overflow: visible;
        border-radius: 30px;
    }

    .sidebar {
        display: none !important;
    }

    .mobile-bottom-nav {
        display: grid !important;
        left: 16px;
        right: 16px;
        bottom: calc(12px + env(safe-area-inset-bottom, 0px));
        gap: 6px;
        padding: 10px;
        border-radius: 24px;
    }

    .mobile-nav-item {
        min-height: 58px;
        gap: 6px;
        font-size: 12px;
        font-weight: 700;
    }

    .mobile-nav-item i {
        font-size: 19px;
    }

    .dashboard-main,
    .main-content {
        width: 100%;
        min-height: 100vh;
        min-height: 100dvh;
        padding: 18px 18px calc(108px + env(safe-area-inset-bottom, 0px));
        overflow-x: hidden;
        overflow-y: visible;
    }

    .content-area,
    .page-content,
    .page-section,
    .responsive-grid {
        gap: 18px;
        padding-right: 0;
        overflow: visible;
    }

    .content-area,
    .page-content {
        padding-bottom: 0;
    }

    .topbar {
        flex-direction: row;
        align-items: flex-start;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 14px;
        padding: 18px 20px;
        border-radius: 24px;
        margin-bottom: 18px;
    }

    .topbar-copy {
        flex: 1 1 340px;
        min-width: 0;
    }

    .topbar-title,
    .page-title {
        font-size: clamp(30px, 4vw, 36px);
        line-height: 1.08;
    }

    .topbar-subtitle,
    .page-subtitle,
    .topbar-copy p {
        font-size: 13px;
        line-height: 1.4;
    }

    .topbar-actions,
    .header-actions {
        width: auto;
        max-width: 100%;
        display: flex;
        flex: 0 1 auto;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: flex-end;
        gap: 10px;
    }

    .header-top-row {
        width: 100%;
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 12px;
        flex-wrap: wrap;
    }

    .header-main-button,
    .mobile-primary-cta-shell {
        width: auto;
        min-width: 200px;
    }

    .header-main-button .btn,
    .header-main-button > a.btn,
    .header-main-button > button.btn {
        width: auto;
        min-width: 180px;
    }

    .dashboard-hero,
    .dashboard-overview-grid,
    .dashboard-grid,
    .cards-grid,
    .summary-grid,
    .summary-two-columns,
    .summary-ledger-grid--two-columns,
    .summary-finance-grid,
    .quick-links-grid,
    .general-summary-grid,
    .expenses-bottom-grid,
    .responsive-grid.two-cols:not(.admin-sequence-grid):not(.admin-cash-box-grid),
    .responsive-grid.three-cols,
    .admin-grid,
    .admin-actions-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 18px !important;
    }

    .dashboard-indicators-card,
    .dashboard-audit-card,
    .delayed-orders-card,
    .summary-balance-strip-card--active,
    .payments-summary-section,
    .summary-expenses-card,
    .full-width,
    .content-card.full-width,
    .table-card,
    .wide-card {
        grid-column: 1 / -1;
    }

    .card,
    .content-card,
    .summary-card,
    .general-summary-card,
    .dashboard-card,
    .table-card,
    .order-services-card {
        padding: 20px;
        border-radius: 22px;
    }

    .dashboard-indicators-card .chart-shell {
        min-height: 300px;
    }

    .dashboard-status-card .chart-shell,
    .donut-chart-shell {
        min-height: 240px;
    }

    .chart-empty-state {
        min-height: 200px;
    }

    .section-head,
    .card-header-row,
    .table-card-header,
    .orders-header,
    .order-form-toolbar,
    .service-compound-toolbar,
    .delayed-orders-content,
    .summary-block-header,
    .dashboard-info-row,
    .total-day-content {
        flex-wrap: wrap;
        align-items: flex-start;
        gap: 12px;
    }

    .orders-header-right,
    .delayed-orders-actions,
    .total-day-actions {
        width: 100%;
        justify-content: space-between;
        gap: 12px;
        flex-wrap: wrap;
    }

    .orders-inline-filters {
        width: 100%;
        justify-content: space-between;
        gap: 12px;
        flex-wrap: wrap;
    }

    .orders-inline-filter-form {
        flex: 1 1 420px;
        flex-wrap: wrap;
        gap: 12px;
        align-items: end;
    }

    .filter-group-inline,
    .orders-filter-field {
        flex: 1 1 220px;
    }

    .form-grid,
    .third-party-form-grid,
    .cash-box-form-grid,
    .summary-header-filters,
    .client-info-grid,
    .search-info-grid--client,
    .search-info-grid--order {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 16px 18px !important;
    }

    .form-grid .full-width,
    .third-party-form-grid .full-width,
    .cash-box-form-grid .full-width,
    .search-info-grid .full-width {
        grid-column: 1 / -1;
    }

    .order-form-grid {
        grid-template-columns: repeat(2, minmax(220px, 1fr)) !important;
        gap: 16px 18px !important;
        align-items: end;
    }

    .order-amounts-row {
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        gap: 16px 18px !important;
    }

    .payment-rounding-row {
        justify-content: flex-start;
    }

    .payments-summary-section .table-wrapper,
    .payments-summary-section table,
    .payments-summary-section .summary-total-box--income,
    .summary-expenses-card .summary-expenses-list,
    .summary-expenses-card table,
    .summary-expenses-card .summary-total-box--expense,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-balance-strip-card--active .summary-balance-strip {
        display: none !important;
    }

    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 14px !important;
        width: 100% !important;
    }

    .mobile-payment-summary-list[hidden],
    .mobile-expenses-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden] {
        display: grid !important;
    }

    .mobile-payment-grand-total,
    .mobile-expense-total-card,
    .mobile-balance-card {
        display: flex !important;
    }

    .mobile-payment-grand-total {
        margin-top: 18px;
    }

    .mobile-balance-card[hidden] {
        display: block !important;
    }

    .mobile-balance-card {
        padding: 0;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .mobile-balance-list {
        gap: 16px;
    }

    .mobile-balance-row strong {
        font-size: clamp(24px, 3.3vw, 30px);
    }

    .mobile-balance-total-card {
        padding: 24px;
    }

    .mobile-balance-total-content strong {
        font-size: clamp(40px, 6vw, 56px);
    }

    .modal,
    .modal-overlay {
        padding: 22px;
    }

    .modal-dialog,
    .modal-content,
    .large-modal,
    .history-modal.modal-content,
    .order-detail-modal-shell,
    .orders-modal-standard,
    .profile-avatar-modal {
        width: min(900px, calc(100vw - 44px));
        max-width: min(900px, calc(100vw - 44px));
        height: auto;
        max-height: calc(100vh - 44px);
        border-radius: 26px;
    }

    .service-picker-modal,
    .add-service-modal {
        width: min(900px, calc(100vw - 44px));
        max-width: min(900px, calc(100vw - 44px));
        max-height: calc(100vh - 44px);
    }

    .modal-header,
    .mobile-modal-header,
    .service-modal-header,
    .orders-modal-header,
    .pending-orders-modal-header,
    .all-orders-modal-header,
    .service-picker-modal-header {
        min-height: 68px !important;
        padding: 16px 20px !important;
        align-items: start !important;
        gap: 14px !important;
    }

    .modal-header h2,
    .modal-header h3,
    .modal-title,
    .mobile-modal-title,
    .service-modal-header h2,
    .service-picker-modal-header h2,
    .service-picker-modal-header h3,
    .orders-modal-title,
    .pending-orders-modal-title,
    .all-orders-modal-title {
        font-size: 22px !important;
        line-height: 1.12 !important;
        font-weight: 700 !important;
    }

    .modal-close,
    .btn-close,
    .mobile-close-btn,
    .modal-close-btn,
    .service-modal-close,
    .orders-modal-close,
    .pending-orders-modal-close,
    .all-orders-modal-close {
        width: 42px !important;
        height: 42px !important;
        min-width: 42px !important;
        min-height: 42px !important;
        border-radius: 14px !important;
    }

    .modal-body,
    .modal-scroll-area,
    .summary-orders-modal .modal-body,
    .all-orders-modal-body,
    .pending-orders-modal-body,
    .delayed-orders-modal-body,
    .client-results-modal-body {
        padding: 18px 20px;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .table-scroll-area,
    .table-wrapper,
    .summary-ledger-table-wrapper,
    .summary-orders-modal-table-shell {
        overflow-x: auto;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table-scroll-area table,
    .table-wrapper table,
    .data-table {
        min-width: 680px;
    }

    .service-picker-layout {
        grid-template-columns: minmax(260px, 300px) minmax(0, 1fr);
        min-height: min(72vh, 760px);
    }

    .service-picker-sidebar {
        padding: 20px;
        max-height: none;
        border-radius: 22px 0 0 22px;
    }

    .service-picker-detail {
        padding: 20px;
    }

    .service-picker-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px 18px;
    }

    .service-picker-form-grid .service-detail-group,
    .service-picker-form-grid .service-price-group,
    .service-compound-section,
    .service-total-card,
    .service-summary-line,
    .service-picker-error,
    .service-picker-actions {
        grid-column: 1 / -1;
    }

    .service-compound-toolbar {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .service-compound-table-shell {
        max-height: 240px;
    }

    .data-table.mobile-card-table,
    .data-table.mobile-card-table thead,
    .data-table.mobile-card-table tbody,
    .data-table.mobile-card-table tr,
    .data-table.mobile-card-table th,
    .data-table.mobile-card-table td {
        display: block;
        width: 100%;
    }

    .data-table.mobile-card-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .data-table.mobile-card-table tbody {
        display: grid;
        gap: 14px;
    }

    .data-table.mobile-card-table tbody tr {
        padding: 16px 18px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
    }

    .data-table.mobile-card-table tbody td {
        border: 0 !important;
        padding: 0 !important;
        margin: 0 0 10px;
        min-width: 0;
    }

    .data-table.mobile-card-table tbody td:last-child {
        margin-bottom: 0;
    }

    .data-table.mobile-card-table tbody td::before {
        content: attr(data-mobile-label);
        display: block;
        margin-bottom: 4px;
        font-size: 11px;
        line-height: 1.2;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        color: #8b8297;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary {
        font-size: 16px;
        line-height: 1.2;
        font-weight: 700;
        color: #304A9A;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary .pill-chip,
    .data-table.mobile-card-table tbody td.mobile-cell--primary strong {
        font-size: 16px;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--amount {
        font-weight: 700;
        color: #304A9A;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .data-table.mobile-card-table tbody td.mobile-cell--amount .pill-chip {
        display: inline-flex;
        width: auto;
        max-width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action {
        margin-top: 4px;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action > *,
    .data-table.mobile-card-table tbody td.mobile-cell--action .action-cell,
    .data-table.mobile-card-table tbody td.mobile-cell--action form {
        width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action button.btn {
        width: 100%;
        justify-content: center;
    }

    .orders-pending-desktop-table,
    .orders-total-desktop-table,
    #allOrdersModal .all-orders-modal-body > .all-orders-desktop-results,
    #allOrdersModal .all-orders-modal-body > .orders-total-table-shell,
    #otherPendingOrdersModal table,
    #otherPendingOrdersModal .pending-orders-desktop-results,
    #otherPendingOrdersModal .desktop-table,
    #otherPendingOrdersModal .desktop-results,
    #otherPendingOrdersModal .delayed-orders-table-shell,
    .third-party-section .table-wrapper,
    .third-party-section .table-scroll-area,
    .terceros-section .table-wrapper,
    .terceros-section .table-scroll-area,
    .expenses-section .table-wrapper,
    .expenses-section .table-scroll-area,
    .gastos-section .table-wrapper,
    .gastos-section .table-scroll-area,
    .closures-section .table-wrapper,
    .closures-section .table-scroll-area,
    .otros-cierres-section .table-wrapper,
    .otros-cierres-section .table-scroll-area,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-section .summary-orders-modal-table-shell,
    .resumen-section .summary-orders-modal-table-shell {
        display: none !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
        width: 100% !important;
    }

    .third-party-mobile-list[hidden],
    .thirdparty-mobile-list[hidden],
    .terceros-mobile-list[hidden],
    .expenses-mobile-list[hidden],
    .gastos-mobile-list[hidden],
    .closures-mobile-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden] {
        display: grid !important;
        grid-template-columns: 1fr !important;
    }

    .orders-pending-mobile-list .mobile-order-card-airy,
    .orders-total-mobile-list .mobile-order-card-airy,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-card-airy,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-card-airy {
        width: 100%;
        box-sizing: border-box;
        padding: 16px;
        border-radius: 18px;
        background: #fff;
        border: 1px solid rgba(190, 220, 230, 0.9);
        box-shadow: 0 4px 12px rgba(38, 55, 90, 0.07);
        overflow: hidden;
    }

    .orders-pending-mobile-list .mobile-order-header,
    .orders-total-mobile-list .mobile-order-header,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-header,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-header,
    .orders-total-mobile-list .mobile-order-card-airy .mobile-order-card-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        margin-bottom: 0;
    }

    .orders-pending-mobile-list .mobile-order-card-airy .mobile-order-code,
    .orders-total-mobile-list .mobile-order-code,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-code,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-code {
        font-size: 16px;
        line-height: 1.15;
        font-weight: 700;
        color: #304A9A;
        word-break: break-word;
    }

    .orders-pending-mobile-list .mobile-order-summary-topline,
    .orders-total-mobile-list .mobile-order-summary-topline,
    .orders-pending-mobile-list .mobile-order-subline,
    .orders-total-mobile-list .mobile-order-subline,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-subline,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-subline {
        margin-top: 5px;
        font-size: 12px;
        line-height: 1.3;
        color: #6F6A7F;
    }

    .orders-pending-mobile-list .mobile-status-pill,
    .orders-pending-mobile-list .mobile-order-status,
    .orders-total-mobile-list .mobile-status-pill,
    .orders-total-mobile-list .mobile-order-status,
    #allOrdersModal .orders-modal-results-mobile .mobile-status-pill,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-status-pill {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 24px;
        padding: 5px 10px;
        border-radius: 999px;
        font-size: 11px;
        line-height: 1;
        font-weight: 700;
        text-transform: uppercase;
        white-space: nowrap;
    }

    .orders-pending-mobile-list .mobile-order-client-box,
    .orders-total-mobile-list .mobile-order-client-box,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-box,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-box {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px;
        margin: 12px 0;
        border-radius: 16px;
        background: #F4F3FF;
    }

    .orders-pending-mobile-list .mobile-order-client-icon,
    .orders-total-mobile-list .mobile-order-client-icon,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-icon,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-icon {
        width: 44px;
        height: 44px;
        flex: 0 0 44px;
        border-radius: 14px;
        background: #E7E6FF;
        color: #4A5BA8;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }

    .orders-pending-mobile-list .mobile-order-client-info,
    .orders-total-mobile-list .mobile-order-client-info,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info {
        min-width: 0;
        flex: 1;
    }

    .orders-pending-mobile-list .mobile-order-client-info strong,
    .orders-total-mobile-list .mobile-order-client-info strong,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info strong,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info strong {
        display: block;
        font-size: 16px;
        line-height: 1.2;
        color: #2F3260;
        font-weight: 700;
    }

    .orders-pending-mobile-list .mobile-order-client-info span,
    .orders-total-mobile-list .mobile-order-client-info span,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-client-info span,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-client-info span {
        display: block;
        margin-top: 3px;
        font-size: 13px;
        line-height: 1.2;
        color: #6F6A7F;
    }

    .orders-pending-mobile-list .mobile-order-metrics-grid,
    .orders-total-mobile-list .mobile-order-metrics-grid,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metrics-grid,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metrics-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
    }

    .orders-pending-mobile-list .mobile-order-metric,
    .orders-total-mobile-list .mobile-order-metric,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric {
        min-width: 0;
        padding: 10px;
        border-radius: 14px;
        background: #F8FAFF;
        border: 1px solid rgba(210, 225, 235, 0.8);
    }

    .orders-pending-mobile-list .mobile-order-metric-icon,
    .orders-total-mobile-list .mobile-order-metric-icon,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric-icon,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric-icon {
        width: 28px;
        height: 28px;
        margin-bottom: 8px;
        border-radius: 999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 13px;
    }

    .orders-pending-mobile-list .mobile-order-metric span,
    .orders-total-mobile-list .mobile-order-metric span,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric span,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric span {
        display: block;
        font-size: 11px;
        line-height: 1.1;
        color: #6F6A7F;
        margin-bottom: 4px;
    }

    .orders-pending-mobile-list .mobile-order-metric strong,
    .orders-total-mobile-list .mobile-order-metric strong,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-metric strong,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-metric strong {
        display: block;
        font-size: 14px;
        line-height: 1.15;
        color: #1F2A5A;
        font-weight: 700;
        word-break: break-word;
    }

    .orders-pending-mobile-list .mobile-order-payment,
    .orders-pending-mobile-list .mobile-order-meta,
    .orders-pending-mobile-list .mobile-order-card-airy > .mobile-order-body:last-of-type,
    .orders-pending-mobile-list .mobile-order-subline,
    .orders-pending-mobile-list .mobile-order-body,
    .orders-total-mobile-list .mobile-order-footer,
    .orders-total-mobile-list .mobile-order-actions,
    .orders-total-mobile-list .mobile-order-subline {
        display: none !important;
    }

    .orders-pending-mobile-list .mobile-order-detail-btn,
    .orders-pending-mobile-list .mobile-order-actions .orders-detail-action-btn,
    .orders-total-mobile-list .mobile-order-detail-btn,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-detail-btn,
    #otherPendingOrdersModal .pending-orders-mobile-results .mobile-order-detail-btn {
        display: flex !important;
        width: 100% !important;
        min-height: 42px;
        align-items: center;
        justify-content: center;
        gap: 8px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 700;
    }

    .orders-total-mobile-list .mobile-order-detail-btn,
    #allOrdersModal .orders-modal-results-mobile .mobile-order-detail-btn {
        background: #4A5BA8;
        color: #fff;
        text-decoration: none;
    }

    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        gap: 14px !important;
    }
}

@media (min-width: 768px) and (max-width: 860px) {
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list,
    .quick-links-grid,
    .dashboard-grid,
    .cards-grid,
    .summary-grid,
    .summary-two-columns,
    .summary-ledger-grid--two-columns,
    .summary-finance-grid,
    .dashboard-overview-grid,
    .dashboard-hero,
    .expenses-bottom-grid {
        grid-template-columns: 1fr !important;
    }

    .order-amounts-row {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .modal-dialog,
    .modal-content,
    .large-modal,
    .history-modal.modal-content,
    .orders-modal-standard,
    .service-picker-modal {
        width: calc(100vw - 36px);
        max-width: calc(100vw - 36px);
    }

    .service-picker-layout {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .service-picker-sidebar {
        border-right: 0;
        border-bottom: 1px solid rgba(85, 156, 173, 0.16);
        border-radius: 22px 22px 0 0;
    }
}

@media (min-width: 900px) and (max-width: 1024px) {
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list,
    .data-table.mobile-card-table tbody {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        align-items: stretch;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results {
        grid-template-columns: 1fr !important;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .orders-pending-desktop-table,
    .orders-total-desktop-table,
    .third-party-section .table-wrapper,
    .third-party-section .table-scroll-area,
    .terceros-section .table-wrapper,
    .terceros-section .table-scroll-area,
    .expenses-section .table-wrapper,
    .expenses-section .table-scroll-area,
    .gastos-section .table-wrapper,
    .gastos-section .table-scroll-area,
    .closures-section .table-wrapper,
    .closures-section .table-scroll-area,
    .otros-cierres-section .table-wrapper,
    .otros-cierres-section .table-scroll-area,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-section .summary-orders-modal-table-shell,
    .resumen-section .summary-orders-modal-table-shell,
    .payments-summary-section .table-wrapper,
    .payments-summary-section table,
    .payments-summary-section .summary-total-box--income,
    .summary-expenses-card .summary-expenses-list,
    .summary-expenses-card table,
    .summary-expenses-card .summary-total-box--expense,
    .summary-balance-strip-card--active .summary-balance-strip,
    #allOrdersModal .all-orders-modal-body > .all-orders-desktop-results,
    #allOrdersModal .all-orders-modal-body > .orders-total-table-shell,
    #otherPendingOrdersModal table,
    #otherPendingOrdersModal .pending-orders-desktop-results,
    #otherPendingOrdersModal .desktop-table,
    #otherPendingOrdersModal .desktop-results,
    #otherPendingOrdersModal .delayed-orders-table-shell {
        display: none !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .mobile-payment-grand-total,
    .mobile-expense-total-card,
    .mobile-balance-card,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results {
        display: grid !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .third-party-mobile-list[hidden],
    .thirdparty-mobile-list[hidden],
    .terceros-mobile-list[hidden],
    .expenses-mobile-list[hidden],
    .gastos-mobile-list[hidden],
    .closures-mobile-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden],
    .mobile-payment-summary-list[hidden],
    .mobile-expenses-list[hidden],
    .mobile-payment-grand-total[hidden],
    .mobile-expense-total-card[hidden],
    .mobile-balance-card[hidden] {
        display: grid !important;
    }

    .mobile-payment-grand-total[hidden],
    .mobile-expense-total-card[hidden],
    .mobile-balance-card[hidden] {
        display: flex !important;
    }

    .table-wrapper,
    .table-scroll-area,
    html,
    body {
        overflow-x: hidden !important;
    }
}

@media (min-width: 901px) and (max-width: 1024px) {
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list,
    .data-table.mobile-card-table tbody {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results {
        grid-template-columns: 1fr !important;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .orders-pending-desktop-table,
    .orders-total-desktop-table,
    #allOrdersModal .all-orders-modal-body > .all-orders-desktop-results,
    #allOrdersModal .all-orders-modal-body > .orders-total-table-shell,
    #otherPendingOrdersModal .pending-orders-desktop-results,
    #otherPendingOrdersModal .delayed-orders-table-shell,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-section .summary-orders-modal-table-shell,
    .resumen-section .summary-orders-modal-table-shell,
    .payments-summary-section .table-wrapper,
    .payments-summary-section table,
    .payments-summary-section .summary-total-box--income,
    .summary-expenses-card .summary-expenses-list,
    .summary-expenses-card table,
    .summary-expenses-card .summary-total-box--expense,
    .summary-balance-strip-card--active .summary-balance-strip,
    .third-party-section .table-wrapper,
    .terceros-section .table-wrapper,
    .expenses-section .table-wrapper,
    .gastos-section .table-wrapper,
    .closures-section .table-wrapper,
    .otros-cierres-section .table-wrapper {
        display: none !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        display: grid !important;
        width: 100% !important;
        max-width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        box-sizing: border-box !important;
    }

    .third-party-mobile-list[hidden],
    .thirdparty-mobile-list[hidden],
    .terceros-mobile-list[hidden],
    .expenses-mobile-list[hidden],
    .gastos-mobile-list[hidden],
    .closures-mobile-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden],
    .mobile-payment-summary-list[hidden],
    .mobile-expenses-list[hidden] {
        display: grid !important;
    }

    .mobile-payment-grand-total,
    .mobile-expense-total-card,
    .mobile-balance-card {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }

    .mobile-payment-grand-total[hidden],
    .mobile-expense-total-card[hidden] {
        display: flex !important;
    }

    .mobile-balance-card[hidden] {
        display: block !important;
    }

    .data-table.mobile-card-table,
    .data-table.mobile-card-table thead,
    .data-table.mobile-card-table tbody,
    .data-table.mobile-card-table tr,
    .data-table.mobile-card-table th,
    .data-table.mobile-card-table td {
        display: block;
        width: 100%;
    }

    .data-table.mobile-card-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .data-table.mobile-card-table tbody {
        display: grid;
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .data-table.mobile-card-table tbody tr {
        padding: 18px 20px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
    }

    .data-table.mobile-card-table tbody td {
        border: 0 !important;
        padding: 0 !important;
        margin: 0 0 10px;
        min-width: 0;
    }

    .data-table.mobile-card-table tbody td:last-child {
        margin-bottom: 0;
    }

    .data-table.mobile-card-table tbody td::before {
        content: attr(data-mobile-label);
        display: block;
        margin-bottom: 4px;
        font-size: 11px;
        line-height: 1.2;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        color: #8b8297;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary {
        font-size: 16px;
        line-height: 1.22;
        font-weight: 700;
        color: #304A9A;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--amount,
    .data-table.mobile-card-table tbody td.mobile-cell--status .pill-chip,
    .data-table.mobile-card-table tbody td.mobile-cell--amount .pill-chip {
        font-weight: 700;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action,
    .data-table.mobile-card-table tbody td.mobile-cell--action > *,
    .data-table.mobile-card-table tbody td.mobile-cell--action .action-cell,
    .data-table.mobile-card-table tbody td.mobile-cell--action form {
        width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action button.btn {
        width: 100%;
        justify-content: center;
    }

    .service-picker-modal .service-picker-layout,
    .add-service-modal .service-picker-layout {
        display: block !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        padding: 0 16px calc(8px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .service-picker-modal .service-picker-sidebar,
    .add-service-modal .service-picker-sidebar {
        padding: 0 !important;
        background: transparent !important;
        border-right: 0 !important;
        border-radius: 0 !important;
        max-height: none !important;
    }

    .service-picker-modal .mobile-service-step-selector,
    .service-picker-modal .mobile-service-step-form,
    .add-service-modal .mobile-service-step-selector,
    .add-service-modal .mobile-service-step-form {
        display: none;
    }

    .service-picker-modal .mobile-service-step-selector.is-active,
    .service-picker-modal .mobile-service-step-form.is-active,
    .add-service-modal .mobile-service-step-selector.is-active,
    .add-service-modal .mobile-service-step-form.is-active {
        display: block;
    }

    .service-picker-modal .service-picker-search,
    .service-picker-modal .mobile-service-search,
    .add-service-modal .service-picker-search,
    .add-service-modal .mobile-service-search {
        position: sticky;
        top: 0;
        z-index: 3;
        margin: 0 0 16px;
    }

    .service-picker-modal .service-picker-list,
    .add-service-modal .service-picker-list {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .service-picker-modal .service-picker-item,
    .add-service-modal .service-picker-item {
        min-height: 84px;
        padding: 14px 16px;
        border-radius: 18px;
    }

    .service-picker-modal .service-picker-detail,
    .add-service-modal .service-picker-detail {
        padding: 0 !important;
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
    }

    .service-picker-modal .service-picker-detail-header,
    .add-service-modal .service-picker-detail-header {
        padding: 16px;
        margin-bottom: 16px;
        border-radius: 18px;
    }

    .service-picker-modal .service-picker-form-grid,
    .add-service-modal .service-picker-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px 18px;
        padding-bottom: 16px;
    }

    .service-picker-modal .service-compound-toolbar,
    .add-service-modal .service-compound-toolbar {
        flex-wrap: wrap;
        gap: 12px;
    }

    .service-picker-modal .service-compound-table-shell,
    .add-service-modal .service-compound-table-shell {
        display: none !important;
    }

    .service-picker-modal .mobile-service-lines-list,
    .add-service-modal .mobile-service-lines-list {
        display: flex !important;
        flex-direction: column;
        gap: 12px;
        margin-top: 14px;
    }

    .mobile-more-sheet {
        left: max(18px, env(safe-area-inset-left, 0px)) !important;
        right: max(18px, env(safe-area-inset-right, 0px)) !important;
        bottom: calc(96px + env(safe-area-inset-bottom, 0px)) !important;
        max-width: 560px;
        margin: 0 auto;
    }

    html,
    body,
    .table-wrapper,
    .table-scroll-area,
    .modal-body,
    .service-picker-layout {
        overflow-x: hidden !important;
    }
}

@media (min-width: 768px) and (max-width: 900px) {
    .service-picker-modal .service-picker-form-grid,
    .add-service-modal .service-picker-form-grid,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .data-table.mobile-card-table tbody {
        grid-template-columns: 1fr !important;
    }
}

@media (min-width: 901px) and (max-width: 1024px) {
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .data-table.mobile-card-table tbody {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        grid-template-columns: 1fr !important;
    }
}

@media (min-width: 1025px) and (max-width: 1366px) and (pointer: coarse),
       (min-width: 1025px) and (max-width: 1366px) and (hover: none) {
    .sidebar {
        display: none !important;
    }

    .mobile-bottom-nav {
        display: grid !important;
        left: 16px;
        right: 16px;
        bottom: calc(12px + env(safe-area-inset-bottom, 0px));
        gap: 6px;
        padding: 10px;
        border-radius: 24px;
    }

    .dashboard-frame {
        padding: 16px;
        min-height: 100vh;
        min-height: 100dvh;
        overflow: hidden;
    }

    .dashboard-shell,
    .app-layout {
        display: block;
        min-height: calc(100vh - 32px);
        min-height: calc(100dvh - 32px);
        height: auto;
        overflow: visible;
        border-radius: 30px;
    }

    .dashboard-main,
    .main-content {
        width: 100%;
        min-height: 100vh;
        min-height: 100dvh;
        padding: 18px 18px calc(108px + env(safe-area-inset-bottom, 0px));
        overflow-x: hidden;
        overflow-y: visible;
    }

    .orders-pending-desktop-table,
    .orders-total-desktop-table,
    #allOrdersModal .all-orders-modal-body > .all-orders-desktop-results,
    #allOrdersModal .all-orders-modal-body > .orders-total-table-shell,
    #otherPendingOrdersModal .pending-orders-desktop-results,
    #otherPendingOrdersModal .delayed-orders-table-shell,
    .summary-orders-block .summary-ledger-table-wrapper,
    .summary-section .summary-orders-modal-table-shell,
    .resumen-section .summary-orders-modal-table-shell,
    .payments-summary-section .table-wrapper,
    .payments-summary-section table,
    .payments-summary-section .summary-total-box--income,
    .summary-expenses-card .summary-expenses-list,
    .summary-expenses-card table,
    .summary-expenses-card .summary-total-box--expense,
    .summary-balance-strip-card--active .summary-balance-strip,
    .third-party-section .table-wrapper,
    .terceros-section .table-wrapper,
    .expenses-section .table-wrapper,
    .gastos-section .table-wrapper,
    .closures-section .table-wrapper,
    .otros-cierres-section .table-wrapper {
        display: none !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .third-party-section .mobile-card-list,
    .terceros-section .mobile-card-list,
    .expenses-section .mobile-card-list,
    .gastos-section .mobile-card-list,
    .closures-section .mobile-card-list,
    .otros-cierres-section .mobile-card-list,
    .summary-section .mobile-card-list,
    .resumen-section .mobile-card-list,
    .mobile-payment-summary-list,
    .mobile-expenses-list,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        display: grid !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 16px !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        box-sizing: border-box !important;
    }

    .orders-pending-mobile-list,
    .orders-total-mobile-list,
    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile,
    #otherPendingOrdersModal .pending-orders-mobile-results,
    .summary-orders-mobile-list,
    .mobile-summary-orders-list {
        grid-template-columns: 1fr !important;
    }

    .third-party-mobile-list[hidden],
    .thirdparty-mobile-list[hidden],
    .terceros-mobile-list[hidden],
    .expenses-mobile-list[hidden],
    .gastos-mobile-list[hidden],
    .closures-mobile-list[hidden],
    .summary-orders-mobile-list[hidden],
    .mobile-summary-orders-list[hidden],
    .mobile-payment-summary-list[hidden],
    .mobile-expenses-list[hidden] {
        display: grid !important;
    }

    .mobile-payment-grand-total,
    .mobile-expense-total-card {
        display: flex !important;
        width: 100% !important;
    }

    .mobile-balance-card,
    .mobile-balance-card[hidden] {
        display: block !important;
        width: 100% !important;
    }

    .data-table.mobile-card-table,
    .data-table.mobile-card-table thead,
    .data-table.mobile-card-table tbody,
    .data-table.mobile-card-table tr,
    .data-table.mobile-card-table th,
    .data-table.mobile-card-table td {
        display: block;
        width: 100%;
    }

    .data-table.mobile-card-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .data-table.mobile-card-table tbody {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .data-table.mobile-card-table tbody tr {
        padding: 18px 20px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid rgba(210, 225, 235, 0.9);
        box-shadow: 0 8px 20px rgba(38, 55, 90, 0.06);
    }

    .data-table.mobile-card-table tbody td {
        border: 0 !important;
        padding: 0 !important;
        margin: 0 0 10px;
        min-width: 0;
    }

    .data-table.mobile-card-table tbody td:last-child {
        margin-bottom: 0;
    }

    .data-table.mobile-card-table tbody td::before {
        content: attr(data-mobile-label);
        display: block;
        margin-bottom: 4px;
        font-size: 11px;
        line-height: 1.2;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.03em;
        color: #8b8297;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--primary {
        font-size: 16px;
        line-height: 1.22;
        font-weight: 700;
        color: #304A9A;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action,
    .data-table.mobile-card-table tbody td.mobile-cell--action > *,
    .data-table.mobile-card-table tbody td.mobile-cell--action .action-cell,
    .data-table.mobile-card-table tbody td.mobile-cell--action form {
        width: 100%;
    }

    .data-table.mobile-card-table tbody td.mobile-cell--action .btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action a.btn,
    .data-table.mobile-card-table tbody td.mobile-cell--action button.btn {
        width: 100%;
        justify-content: center;
    }

    .service-picker-modal .service-picker-layout,
    .add-service-modal .service-picker-layout {
        display: block !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        padding: 0 22px calc(8px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .service-picker-modal .service-picker-sidebar,
    .add-service-modal .service-picker-sidebar {
        padding: 0 !important;
        background: transparent !important;
        border-right: 0 !important;
        border-radius: 0 !important;
        max-height: none !important;
    }

    .service-picker-modal .mobile-service-step-selector,
    .service-picker-modal .mobile-service-step-form,
    .add-service-modal .mobile-service-step-selector,
    .add-service-modal .mobile-service-step-form {
        display: none;
    }

    .service-picker-modal .mobile-service-step-selector.is-active,
    .service-picker-modal .mobile-service-step-form.is-active,
    .add-service-modal .mobile-service-step-selector.is-active,
    .add-service-modal .mobile-service-step-form.is-active {
        display: block;
    }

    .service-picker-modal .service-picker-search,
    .service-picker-modal .mobile-service-search,
    .add-service-modal .service-picker-search,
    .add-service-modal .mobile-service-search {
        position: sticky;
        top: 0;
        z-index: 3;
        margin: 0 0 16px;
    }

    .service-picker-modal .service-picker-list,
    .add-service-modal .service-picker-list {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .service-picker-modal .service-picker-detail,
    .add-service-modal .service-picker-detail {
        padding: 0 !important;
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
    }

    .service-picker-modal .service-compound-table-shell,
    .add-service-modal .service-compound-table-shell {
        display: none !important;
    }

    .service-picker-modal .mobile-service-lines-list,
    .add-service-modal .mobile-service-lines-list {
        display: flex !important;
        flex-direction: column;
        gap: 12px;
        margin-top: 14px;
    }

    .mobile-more-sheet {
        left: max(18px, env(safe-area-inset-left, 0px)) !important;
        right: max(18px, env(safe-area-inset-right, 0px)) !important;
        bottom: calc(96px + env(safe-area-inset-bottom, 0px)) !important;
        max-width: 560px;
        margin: 0 auto;
    }

    html,
    body,
    .table-wrapper,
    .table-scroll-area,
    .modal-body,
    .service-picker-layout {
        overflow-x: hidden !important;
    }
}

@media (min-width: 768px) and (max-width: 1024px),
       (min-width: 1025px) and (max-width: 1366px) and (pointer: coarse),
       (min-width: 1025px) and (max-width: 1366px) and (hover: none) {
    .tablet-card-hide {
        display: none !important;
    }

    .tablet-card-show-column {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 16px !important;
    }

    .tablet-card-show-grid {
        display: grid !important;
        width: 100% !important;
        max-width: 100% !important;
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .tablet-card-show-flex {
        display: flex !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .tablet-card-show-block {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
    }
}

@media (min-width: 901px) and (max-width: 1024px),
       (min-width: 1025px) and (max-width: 1366px) and (pointer: coarse) and (orientation: landscape),
       (min-width: 1025px) and (max-width: 1366px) and (hover: none) and (orientation: landscape) {
    .expenses-mobile-list.tablet-card-show-grid,
    .gastos-mobile-list.tablet-card-show-grid,
    .third-party-mobile-list.tablet-card-show-grid,
    .thirdparty-mobile-list.tablet-card-show-grid,
    .terceros-mobile-list.tablet-card-show-grid,
    .closures-mobile-list.tablet-card-show-grid,
    .mobile-payment-summary-list.tablet-card-show-grid,
    .mobile-expenses-list.tablet-card-show-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .orders-pending-mobile-list.tablet-card-show-column,
    .orders-total-mobile-list.tablet-card-show-column,
    .mobile-summary-orders-list.tablet-card-show-column,
    .summary-orders-mobile-list.tablet-card-show-column {
        display: flex !important;
        flex-direction: column !important;
    }
}

.tablet-app-mode .tablet-card-hide {
    display: none !important;
}

.tablet-app-mode .tablet-card-show-column {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    gap: 16px !important;
}

.tablet-app-mode .tablet-card-show-grid {
    display: grid !important;
    width: 100% !important;
    max-width: 100% !important;
    grid-template-columns: 1fr !important;
    gap: 16px !important;
}

.tablet-app-mode .tablet-card-show-flex {
    display: flex !important;
    width: 100% !important;
    max-width: 100% !important;
}

.tablet-app-mode .tablet-card-show-block {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
}

.tablet-app-mode .sidebar {
    display: none !important;
}

.tablet-app-mode .mobile-bottom-nav {
    display: grid !important;
}

.tablet-app-mode .orders-pending-mobile-list.tablet-card-show-column,
.tablet-app-mode .orders-total-mobile-list.tablet-card-show-column,
.tablet-app-mode .mobile-summary-orders-list.tablet-card-show-column,
.tablet-app-mode .summary-orders-mobile-list.tablet-card-show-column {
    display: flex !important;
    flex-direction: column !important;
}

.tablet-app-mode .expenses-mobile-list.tablet-card-show-grid,
.tablet-app-mode .gastos-mobile-list.tablet-card-show-grid,
.tablet-app-mode .third-party-mobile-list.tablet-card-show-grid,
.tablet-app-mode .thirdparty-mobile-list.tablet-card-show-grid,
.tablet-app-mode .terceros-mobile-list.tablet-card-show-grid,
.tablet-app-mode .closures-mobile-list.tablet-card-show-grid,
.tablet-app-mode .mobile-payment-summary-list.tablet-card-show-grid,
.tablet-app-mode .mobile-expenses-list.tablet-card-show-grid {
    grid-template-columns: 1fr !important;
}

@media (orientation: landscape) {
    .tablet-app-mode .expenses-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .gastos-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .third-party-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .thirdparty-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .terceros-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .closures-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .mobile-payment-summary-list.tablet-card-show-grid,
    .tablet-app-mode .mobile-expenses-list.tablet-card-show-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .tablet-app-mode .orders-pending-mobile-list.tablet-card-show-column,
    .tablet-app-mode .orders-total-mobile-list.tablet-card-show-column,
    .tablet-app-mode .mobile-summary-orders-list.tablet-card-show-column,
    .tablet-app-mode .summary-orders-mobile-list.tablet-card-show-column {
        display: flex !important;
        flex-direction: column !important;
    }
}

.tablet-app-mode .dashboard-frame {
    padding: 12px !important;
    height: auto !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    overflow: visible !important;
}

.tablet-app-mode,
.tablet-app-mode body {
    height: auto !important;
    min-height: 100% !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
}

.tablet-app-mode .dashboard-shell,
.tablet-app-mode .app-layout {
    display: block !important;
    height: auto !important;
    min-height: calc(100vh - 24px) !important;
    min-height: calc(100dvh - 24px) !important;
    overflow: visible !important;
}

.tablet-app-mode .dashboard-main,
.tablet-app-mode .main-content {
    height: auto !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    padding: 12px 12px calc(92px + env(safe-area-inset-bottom, 0px)) !important;
    overflow-x: hidden !important;
    overflow-y: visible !important;
}

.tablet-app-mode .content-area,
.tablet-app-mode .page-content {
    padding-bottom: 0 !important;
    min-height: 0 !important;
    flex: 0 0 auto !important;
    overflow-x: hidden !important;
    overflow-y: visible !important;
    padding-right: 0 !important;
}

.tablet-app-mode .topbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    grid-template-areas:
        "copy actions"
        "cta cta" !important;
    align-items: start !important;
    gap: 14px !important;
    padding: 16px !important;
    border-radius: 22px !important;
}

.tablet-app-mode .topbar-copy {
    grid-area: copy !important;
    width: 100% !important;
    min-width: 0 !important;
}

.tablet-app-mode .topbar-actions {
    display: contents !important;
}

.tablet-app-mode .header-top-row {
    grid-area: actions !important;
    width: auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 14px !important;
    flex-wrap: nowrap !important;
    align-self: start !important;
}

.tablet-app-mode .delayed-orders-content {
    height: auto !important;
    width: 100% !important;
    flex-direction: row !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    gap: 18px !important;
}

.tablet-app-mode .delayed-orders-actions {
    width: auto !important;
    justify-content: flex-end !important;
    align-items: flex-start !important;
    flex-wrap: nowrap !important;
}

.tablet-app-mode .delayed-orders-count-stack {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    gap: 4px !important;
    text-align: right !important;
}

.tablet-app-mode .delayed-orders-count {
    font-size: clamp(36px, 5vw, 40px) !important;
}

.tablet-app-mode .delayed-orders-card {
    display: flex !important;
    flex-direction: column !important;
    padding: 20px !important;
    border-radius: 24px !important;
    overflow: visible !important;
}

.tablet-app-mode .delayed-orders-info h3 {
    margin: 8px 0 10px !important;
    font-size: clamp(20px, 2.8vw, 22px) !important;
    line-height: 1.2 !important;
}

.tablet-app-mode .delayed-orders-info p {
    font-size: 14px !important;
    line-height: 1.35 !important;
}

.tablet-app-mode .alert-label {
    font-size: 12px !important;
    letter-spacing: 0.06em !important;
}

.tablet-app-mode .delayed-orders-count-label {
    font-size: 13px !important;
    line-height: 1.2 !important;
    color: #736278 !important;
}

.tablet-app-mode .delayed-orders-action-desktop {
    display: none !important;
}

.tablet-app-mode .delayed-orders-action-mobile-wrap {
    display: block !important;
    width: 100% !important;
    margin-top: 16px !important;
}

.tablet-app-mode .delayed-orders-action-mobile {
    display: inline-flex !important;
    width: 100% !important;
    justify-content: center !important;
    min-height: 46px !important;
    border-radius: 18px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
}

@media (max-width: 1024px) {
    .delayed-orders-card {
        display: flex !important;
        flex-direction: column !important;
        gap: 0 !important;
        padding: 18px 20px !important;
        border-radius: 22px !important;
        overflow: visible !important;
    }

    .delayed-orders-content {
        width: 100% !important;
        height: auto !important;
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) auto !important;
        align-items: start !important;
        gap: 16px !important;
    }

    .delayed-orders-info {
        min-width: 0 !important;
    }

    .delayed-orders-info h3 {
        margin: 8px 0 10px !important;
        font-size: clamp(20px, 2.7vw, 22px) !important;
        line-height: 1.2 !important;
        word-break: normal !important;
        overflow-wrap: normal !important;
    }

    .delayed-orders-info p {
        margin: 0 !important;
        font-size: 14px !important;
        line-height: 1.35 !important;
    }

    .alert-label {
        font-size: 12px !important;
        line-height: 1.2 !important;
        letter-spacing: 0.04em !important;
        font-weight: 700 !important;
    }

    .delayed-orders-actions {
        width: auto !important;
        display: flex !important;
        align-items: flex-start !important;
        justify-content: flex-end !important;
        flex-wrap: nowrap !important;
        gap: 0 !important;
    }

    .delayed-orders-count-stack {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-end !important;
        justify-content: center !important;
        text-align: right !important;
        gap: 4px !important;
    }

    .delayed-orders-count {
        font-size: clamp(36px, 5vw, 40px) !important;
        line-height: 1 !important;
        color: #4a5899 !important;
        font-weight: 700 !important;
    }

    .delayed-orders-count-label {
        margin-top: 0 !important;
        font-size: 13px !important;
        line-height: 1.2 !important;
        color: #736278 !important;
        opacity: 1 !important;
    }

    .delayed-orders-action-desktop {
        display: none !important;
    }

    .delayed-orders-action-mobile-wrap {
        display: block !important;
        width: 100% !important;
        margin-top: 16px !important;
    }

    .delayed-orders-action-mobile {
        display: inline-flex !important;
        width: 100% !important;
        min-height: 46px !important;
        justify-content: center !important;
        align-items: center !important;
        border-radius: 18px !important;
        font-size: 15px !important;
        font-weight: 700 !important;
    }
}

@media (max-width: 430px) {
    .delayed-orders-card {
        padding: 16px !important;
    }

    .delayed-orders-content {
        gap: 12px !important;
    }

    .delayed-orders-info h3 {
        font-size: 19px !important;
    }

    .delayed-orders-info p {
        font-size: 13px !important;
    }

    .delayed-orders-count {
        font-size: 34px !important;
    }

    .delayed-orders-count-label {
        font-size: 12px !important;
    }

    .delayed-orders-action-mobile {
        min-height: 44px !important;
        font-size: 14px !important;
    }
}

@media (min-width: 768px) and (max-width: 900px) {
    .dashboard-main,
    .main-content {
        padding: 16px 16px calc(100px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .content-area,
    .page-content,
    .dashboard-overview-grid,
    .admin-actions-grid,
    .dashboard-grid,
    .cards-grid,
    .summary-grid,
    .general-summary-grid {
        gap: 14px !important;
    }

    .topbar {
        padding: 16px 18px !important;
        margin-bottom: 14px !important;
    }

    .card,
    .content-card,
    .summary-card,
    .general-summary-card,
    .dashboard-card,
    .table-card {
        padding: 18px !important;
        border-radius: 20px !important;
    }

    .dashboard-audit-card {
        padding: 18px !important;
    }

    .dashboard-audit-header {
        gap: 10px !important;
        margin-bottom: 12px !important;
    }

    .dashboard-audit-grid,
    .dashboard-audit-card .kpi-card-grid,
    .dashboard-audit-card .kpi-card-grid--four {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 12px !important;
    }

    .dashboard-audit-card .general-summary-item,
    .dashboard-audit-card .kpi-card {
        min-height: 82px !important;
        padding: 14px 16px !important;
        gap: 12px !important;
    }

    .dashboard-audit-card .general-summary-item .info-chip-label,
    .dashboard-audit-card .kpi-card .info-chip-label {
        font-size: 12px !important;
        line-height: 1.2 !important;
    }

    .dashboard-audit-card .general-summary-item strong,
    .dashboard-audit-card .kpi-card strong {
        font-size: clamp(22px, 3vw, 26px) !important;
        line-height: 1 !important;
    }

    .audit-action-mobile-wrap {
        margin-top: 12px !important;
    }

    .audit-action-mobile {
        min-height: 46px !important;
    }

    .delayed-orders-card {
        padding: 18px !important;
        min-height: 0 !important;
    }

    .delayed-orders-content {
        gap: 14px !important;
    }

    .delayed-orders-info h3 {
        margin: 6px 0 8px !important;
        font-size: 21px !important;
        line-height: 1.18 !important;
    }

    .delayed-orders-info p {
        font-size: 14px !important;
        line-height: 1.32 !important;
    }

    .delayed-orders-count {
        font-size: 37px !important;
    }

    .delayed-orders-count-label {
        font-size: 12px !important;
    }

    .delayed-orders-action-mobile-wrap {
        margin-top: 14px !important;
    }

    .delayed-orders-action-mobile {
        min-height: 46px !important;
    }
}

.tablet-app-mode .mobile-header-notification {
    flex: 0 0 auto !important;
    justify-self: auto !important;
}

.tablet-app-mode .header-datetime,
.tablet-app-mode .mobile-header-time-block {
    flex: 0 0 auto !important;
    justify-self: auto !important;
    text-align: right !important;
    min-width: max-content !important;
}

.tablet-app-mode .mobile-primary-cta,
.tablet-app-mode .btn-nueva-orden,
.tablet-app-mode .header-main-button .btn,
.tablet-app-mode .header-main-button > a.btn,
.tablet-app-mode .header-main-button > button.btn {
    width: 100% !important;
    min-height: 46px !important;
    justify-content: center !important;
}

.tablet-app-mode .header-main-button {
    grid-area: cta !important;
    width: 100% !important;
    margin-top: 2px !important;
}

.tablet-app-mode .form-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    align-items: stretch !important;
}

.tablet-app-mode .form-actions .btn,
.tablet-app-mode .form-actions a.btn,
.tablet-app-mode .form-actions button.btn,
.tablet-app-mode .secondary-top-action-btn,
.tablet-app-mode .orders-secondary-action-btn,
.tablet-app-mode .mobile-view-all-button,
.tablet-app-mode .btn-secondary-action-outline,
.tablet-app-mode .orders-detail-action-btn,
.tablet-app-mode .mobile-card-action,
.tablet-app-mode .mobile-thirdparty-action,
.tablet-app-mode .mobile-order-detail-btn,
.tablet-app-mode .mobile-secondary-action,
.tablet-app-mode .mobile-danger-action,
.tablet-app-mode .mobile-expense-edit,
.tablet-app-mode .mobile-expense-delete {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 44px !important;
    justify-content: center !important;
    font-size: 14px !important;
    font-weight: 700 !important;
}

.tablet-app-mode .table-card-header .btn,
.tablet-app-mode .summary-block-header .btn,
.tablet-app-mode .orders-header-right .btn,
.tablet-app-mode .delayed-orders-actions .btn {
    width: 100% !important;
}

.tablet-app-mode .mobile-order-actions,
.tablet-app-mode .mobile-card-secondary-actions,
.tablet-app-mode .mobile-expense-actions,
.tablet-app-mode .mobile-service-card-actions {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
}

.tablet-app-mode .card,
.tablet-app-mode .content-card,
.tablet-app-mode .summary-card,
.tablet-app-mode .table-card,
.tablet-app-mode .dashboard-card,
.tablet-app-mode .order-services-card {
    padding: 16px !important;
    border-radius: 20px !important;
    gap: 16px;
}

.tablet-app-mode .section-title,
.tablet-app-mode .page-title,
.tablet-app-mode .topbar-title {
    font-size: 18px !important;
    line-height: 1.15 !important;
    font-weight: 700 !important;
}

.tablet-app-mode .section-subtitle,
.tablet-app-mode .topbar-subtitle,
.tablet-app-mode .page-subtitle {
    font-size: 13px !important;
    line-height: 1.35 !important;
}

.tablet-app-mode .mobile-bottom-nav {
    left: 8px !important;
    right: 8px !important;
    bottom: calc(8px + env(safe-area-inset-bottom, 0px)) !important;
    border-radius: 20px !important;
}

.tablet-app-mode input,
.tablet-app-mode select,
.tablet-app-mode textarea {
    min-height: 44px !important;
}

.tablet-app-mode .mobile-data-card,
.tablet-app-mode .mobile-summary-order-card,
.tablet-app-mode .mobile-payment-summary-card,
.tablet-app-mode .mobile-expense-card,
.tablet-app-mode .mobile-expense-card-v3,
.tablet-app-mode .mobile-thirdparty-card-v1,
.tablet-app-mode .mobile-closure-card,
.tablet-app-mode .mobile-order-card-airy {
    width: 100% !important;
    box-sizing: border-box !important;
    padding: 14px !important;
    border-radius: 18px !important;
    background: #fff !important;
    border: 1px solid rgba(190, 220, 230, 0.9) !important;
    box-shadow: 0 4px 12px rgba(38,55,90,.07) !important;
    overflow: hidden !important;
}

.tablet-app-mode .mobile-summary-orders-list,
.tablet-app-mode .summary-orders-mobile-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    width: 100% !important;
}

.tablet-app-mode .mobile-summary-orders-list[hidden],
.tablet-app-mode .summary-orders-mobile-list[hidden] {
    display: flex !important;
}

.tablet-app-mode .mobile-summary-order-top {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    gap: 12px !important;
    margin-bottom: 10px !important;
}

.tablet-app-mode .mobile-summary-order-main {
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px !important;
}

.tablet-app-mode .mobile-summary-order-side {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    gap: 8px !important;
}

.tablet-app-mode .mobile-order-code-pill,
.tablet-app-mode .mobile-order-status,
.tablet-app-mode .mobile-payment-pill,
.tablet-app-mode .mobile-status-pill,
.tablet-app-mode .mobile-meta-pill,
.tablet-app-mode .mobile-method-pill {
    font-weight: 700 !important;
}

.tablet-app-mode .mobile-summary-order-metrics {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
}

.tablet-app-mode .mobile-summary-metric {
    min-width: 0 !important;
    padding: 10px !important;
    border-radius: 14px !important;
    background: #F8FAFF !important;
    border: 1px solid rgba(210,225,235,.75) !important;
}

.tablet-app-mode .mobile-payment-summary-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    width: 100% !important;
}

.tablet-app-mode .mobile-payment-summary-list[hidden] {
    display: flex !important;
}

.tablet-app-mode .mobile-payment-summary-card {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto auto !important;
    align-items: center !important;
    gap: 14px !important;
    min-height: 88px !important;
}

.tablet-app-mode .mobile-payment-summary-left {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    min-width: 0 !important;
}

.tablet-app-mode .mobile-payment-info {
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 6px !important;
}

.tablet-app-mode .mobile-payment-total {
    font-size: 24px !important;
    line-height: 1 !important;
    font-weight: 700 !important;
    color: #304A9A !important;
    text-align: right !important;
    white-space: nowrap !important;
    margin-left: auto !important;
}

.tablet-app-mode .mobile-payment-grand-total,
.tablet-app-mode .mobile-payment-grand-total[hidden] {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
    margin-top: 16px !important;
    padding: 18px !important;
    border-radius: 22px !important;
    background: linear-gradient(180deg, #F5FFF8 0%, #F2FBF5 100%) !important;
    border: 1px solid rgba(180,230,195,.9) !important;
}

.tablet-app-mode .mobile-payment-grand-total strong {
    margin-left: auto !important;
    text-align: right !important;
}

.tablet-app-mode .mobile-expenses-list,
.tablet-app-mode .mobile-expenses-list[hidden] {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    width: 100% !important;
}

.tablet-app-mode .register-order-card,
.tablet-app-mode .order-entry-card,
.tablet-app-mode .client-search-card,
.tablet-app-mode .summary-block,
.tablet-app-mode .summary-card,
.tablet-app-mode .payments-summary-section,
.tablet-app-mode .summary-expenses-card,
.tablet-app-mode .summary-balance-strip-card--active,
.tablet-app-mode .third-party-section,
.tablet-app-mode .expenses-section,
.tablet-app-mode .closures-section {
    overflow: hidden !important;
}

.tablet-app-mode .mobile-expense-card {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 14px !important;
}

.tablet-app-mode .mobile-expense-left {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    min-width: 0 !important;
    flex: 1 !important;
}

.tablet-app-mode .mobile-expense-title {
    color: #304A9A !important;
    font-size: 18px !important;
    font-weight: 700 !important;
}

.tablet-app-mode .mobile-expense-amount {
    font-size: 24px !important;
    line-height: 1 !important;
    font-weight: 700 !important;
    color: #304A9A !important;
    text-align: right !important;
    white-space: nowrap !important;
}

.tablet-app-mode .mobile-expense-total-card,
.tablet-app-mode .mobile-expense-total-card[hidden] {
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    margin-top: 18px !important;
    padding: 18px !important;
    border-radius: 24px !important;
}

.tablet-app-mode .mobile-expense-total-info strong {
    font-size: 42px !important;
    line-height: 1 !important;
    font-weight: 700 !important;
}

.tablet-app-mode .mobile-third-party-card,
.tablet-app-mode .mobile-thirdparty-card {
    display: none !important;
}

.tablet-app-mode .mobile-thirdparty-card-v1,
.tablet-app-mode .mobile-thirdparty-card-v1[hidden] {
    display: block !important;
}

.tablet-app-mode .mobile-thirdparty-header {
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    gap: 10px !important;
    margin-bottom: 12px !important;
}

.tablet-app-mode .mobile-thirdparty-title {
    font-size: 16px !important;
    line-height: 1.15 !important;
    font-weight: 700 !important;
    color: #304A9A !important;
}

.tablet-app-mode .mobile-thirdparty-subtitle {
    margin-top: 5px !important;
    font-size: 12px !important;
    line-height: 1.3 !important;
    color: #6F6A7F !important;
}

.tablet-app-mode .mobile-thirdparty-highlight {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 12px !important;
    margin-bottom: 12px !important;
    border-radius: 16px !important;
    background: #F4F3FF !important;
}

.tablet-app-mode .mobile-thirdparty-metrics {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
}

.tablet-app-mode .mobile-thirdparty-metric {
    min-width: 0 !important;
    padding: 10px !important;
    border-radius: 14px !important;
    background: #F8FAFF !important;
    border: 1px solid rgba(210,225,235,.8) !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
}

.tablet-app-mode .mobile-thirdparty-action {
    display: flex !important;
    width: 100% !important;
    min-height: 42px !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    border-radius: 12px !important;
    background: #4A5BA8 !important;
    color: #fff !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
}

.tablet-app-mode .mobile-balance-card,
.tablet-app-mode .mobile-balance-card[hidden] {
    display: block !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

.tablet-app-mode .mobile-balance-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    margin-bottom: 18px !important;
}

.tablet-app-mode .mobile-balance-row {
    width: 100% !important;
    min-height: 84px !important;
    padding: 16px !important;
    border-radius: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    box-sizing: border-box !important;
}

.tablet-app-mode .mobile-balance-total-card {
    width: 100% !important;
    padding: 22px !important;
    border-radius: 24px !important;
    background: linear-gradient(180deg, #F8F8FF 0%, #F3F4FF 100%) !important;
    border: 1px solid rgba(205,210,255,.9) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    text-align: center !important;
}

.tablet-app-mode .mobile-balance-total-icon {
    display: none !important;
}

.tablet-app-mode .mobile-balance-total-content strong {
    font-size: clamp(34px, 7vw, 52px) !important;
    line-height: 1 !important;
    font-weight: 700 !important;
    color: #3046C9 !important;
}

.tablet-app-mode .mobile-balance-total-content small {
    margin: 0 auto !important;
}

.tablet-app-mode .mobile-card-list,
.tablet-app-mode .third-party-mobile-list,
.tablet-app-mode .thirdparty-mobile-list,
.tablet-app-mode .terceros-mobile-list,
.tablet-app-mode .expenses-mobile-list,
.tablet-app-mode .gastos-mobile-list,
.tablet-app-mode .closures-mobile-list {
    gap: 12px !important;
}

@media (orientation: portrait) {
    .tablet-app-mode .summary-grid,
    .tablet-app-mode .summary-two-columns,
    .tablet-app-mode .summary-finance-grid,
    .tablet-app-mode .responsive-grid.two-cols,
    .tablet-app-mode .expenses-bottom-grid,
    .tablet-app-mode .form-grid,
    .tablet-app-mode .third-party-form-grid,
    .tablet-app-mode .cash-box-form-grid,
    .tablet-app-mode .order-form-grid,
    .tablet-app-mode .search-info-grid--client,
    .tablet-app-mode .search-info-grid--order,
    .tablet-app-mode .client-info-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .tablet-app-mode .mobile-payment-summary-list.tablet-card-show-grid,
    .tablet-app-mode .mobile-expenses-list.tablet-card-show-grid,
    .tablet-app-mode .third-party-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .thirdparty-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .terceros-mobile-list.tablet-card-show-grid,
    .tablet-app-mode .closures-mobile-list.tablet-card-show-grid {
        grid-template-columns: 1fr !important;
    }

    .tablet-app-mode .general-summary-grid,
    .tablet-app-mode .expenses-bottom-grid,
    .tablet-app-mode .dashboard-grid,
    .tablet-app-mode .cards-grid,
    .tablet-app-mode .responsive-grid.three-cols,
    .tablet-app-mode .admin-grid,
    .tablet-app-mode .admin-actions-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .tablet-app-mode .table-card-header,
    .tablet-app-mode .summary-block-header,
    .tablet-app-mode .orders-header,
    .tablet-app-mode .section-header,
    .tablet-app-mode .card-header-row {
        display: grid !important;
        grid-template-columns: 1fr !important;
        align-items: start !important;
    }

    .tablet-app-mode .table-card-header > *,
    .tablet-app-mode .summary-block-header > *,
    .tablet-app-mode .orders-header > * {
        width: 100% !important;
    }

    .tablet-app-mode .mobile-payment-summary-card {
        grid-template-columns: minmax(0, 1fr) auto !important;
        grid-template-areas:
            "info amount"
            "info cta" !important;
        align-items: center !important;
    }

    .tablet-app-mode .mobile-payment-summary-left {
        grid-area: info !important;
    }

    .tablet-app-mode .mobile-payment-total {
        grid-area: amount !important;
    }

    .tablet-app-mode .mobile-payment-open-btn {
        grid-area: cta !important;
        justify-self: end !important;
    }

    .tablet-app-mode .mobile-expense-card {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .tablet-app-mode .mobile-expense-left {
        width: 100% !important;
    }

    .tablet-app-mode .mobile-expense-amount {
        width: 100% !important;
        margin-left: 0 !important;
        text-align: left !important;
    }

    .tablet-app-mode .mobile-balance-row {
        padding: 14px !important;
    }

    .tablet-app-mode .mobile-balance-row strong {
        font-size: 22px !important;
    }
}

/* All orders modal: desktop keeps the table, tablet/mobile use the card list. */
.all-orders-mobile-results,
.orders-modal-results-mobile,
#allOrdersModal .all-orders-mobile-results,
#allOrdersModal .orders-modal-results-mobile {
    display: none !important;
    position: static !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
}

#allOrdersModal .all-orders-desktop-results,
#allOrdersModal .orders-total-table-shell,
#allOrdersModal .table-wrapper.orders-total-table-shell {
    display: block !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: auto !important;
}

#allOrdersModal .orders-total-table-shell table {
    display: table !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
}

#allOrdersModal .orders-total-table-shell thead {
    display: table-header-group !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
}

#allOrdersModal .orders-total-table-shell tbody {
    display: table-row-group !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
}

@media (max-width: 1024px) {
    #allOrdersModal .all-orders-desktop-results,
    #allOrdersModal .orders-total-table-shell,
    #allOrdersModal .table-wrapper.orders-total-table-shell {
        display: none !important;
    }

    #allOrdersModal .all-orders-mobile-results,
    #allOrdersModal .orders-modal-results-mobile {
        display: flex !important;
        flex-direction: column !important;
        gap: 14px !important;
        width: 100% !important;
        position: static !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }
}

.tablet-app-mode #allOrdersModal .all-orders-desktop-results,
.tablet-app-mode #allOrdersModal .orders-total-table-shell,
.tablet-app-mode #allOrdersModal .table-wrapper.orders-total-table-shell {
    display: none !important;
}

.tablet-app-mode #allOrdersModal .all-orders-mobile-results,
.tablet-app-mode #allOrdersModal .orders-modal-results-mobile {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    width: 100% !important;
    position: static !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    overflow: visible !important;
}

/* Orders modals reuse the same autocomplete component used by Ingreso/Busqueda. */
#allOrdersModal .modal-search-autocomplete,
#otherPendingOrdersModal .modal-search-autocomplete {
    position: relative !important;
    overflow: visible !important;
    z-index: 60 !important;
}

#allOrdersModal .modal-search-suggestions,
#otherPendingOrdersModal .modal-search-suggestions {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 9999 !important;
    max-height: 320px !important;
    overflow-y: auto !important;
    background: #ffffff !important;
    border: 1px solid #d8e7ef !important;
    border-radius: 16px !important;
    box-shadow: 0 18px 36px rgba(55, 48, 90, 0.12) !important;
    padding: 8px !important;
}

/* Service lines: desktop keeps the table, mobile/tablet-app-mode use cards. */
.service-picker-modal .mobile-service-lines-list,
.add-service-modal .mobile-service-lines-list,
.service-picker-modal .mobile-service-line-card,
.add-service-modal .mobile-service-line-card {
    display: none !important;
}

.service-picker-modal .service-compound-table-shell,
.add-service-modal .service-compound-table-shell {
    display: block !important;
}

@media (max-width: 768px) {
    .service-picker-modal .mobile-service-lines-list,
    .add-service-modal .mobile-service-lines-list {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
    }

    .service-picker-modal .mobile-service-line-card,
    .add-service-modal .mobile-service-line-card {
        display: block !important;
    }

    .service-picker-modal .service-compound-table-shell,
    .add-service-modal .service-compound-table-shell {
        display: none !important;
    }
}

body.tablet-app-mode .service-picker-modal .mobile-service-lines-list,
body.tablet-app-mode .add-service-modal .mobile-service-lines-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
}

body.tablet-app-mode .service-picker-modal .mobile-service-line-card,
body.tablet-app-mode .add-service-modal .mobile-service-line-card {
    display: block !important;
}

body.tablet-app-mode .service-picker-modal .service-compound-table-shell,
body.tablet-app-mode .add-service-modal .service-compound-table-shell {
    display: none !important;
}

#allOrdersModal .modal-search-suggestions[hidden],
#otherPendingOrdersModal .modal-search-suggestions[hidden] {
    display: none !important;
}

#allOrdersModal .modal-search-suggestion-item.client-search-result-item,
#otherPendingOrdersModal .modal-search-suggestion-item.client-search-result-item {
    width: 100% !important;
    border: 0 !important;
    background: transparent !important;
    border-radius: 12px !important;
    padding: 10px 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
    text-align: left !important;
    cursor: pointer !important;
    color: #33427f !important;
}

#allOrdersModal .modal-search-suggestion-item.client-search-result-item:hover,
#allOrdersModal .modal-search-suggestion-item.client-search-result-item:focus-visible,
#otherPendingOrdersModal .modal-search-suggestion-item.client-search-result-item:hover,
#otherPendingOrdersModal .modal-search-suggestion-item.client-search-result-item:focus-visible {
    background: #f9fafb !important;
    outline: none !important;
}

#allOrdersModal .modal-search-suggestion-item .client-search-result-left,
#otherPendingOrdersModal .modal-search-suggestion-item .client-search-result-left {
    min-width: 0 !important;
    flex: 1 1 auto !important;
}

#allOrdersModal .modal-search-suggestion-item .client-dni-pill,
#otherPendingOrdersModal .modal-search-suggestion-item .client-dni-pill {
    min-width: 112px !important;
    max-width: 180px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}
.orders-modal-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  flex-shrink: 0;
  margin-top: 16px;
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid rgba(201, 217, 240, 0.75);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 10px 26px rgba(52, 68, 134, 0.08);
}

.orders-modal-pagination-summary,
.orders-modal-pagination-status,
.orders-server-helper-text,
.order-detail-loading-state {
  color: #6f6a7f;
  font-size: 14px;
  line-height: 1.4;
}

.orders-modal-pagination-summary,
.orders-modal-pagination-status {
  font-weight: 600;
}

.orders-modal-pagination-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.orders-modal-page-btn {
  min-width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(177, 197, 238, 0.9);
  background: #ffffff;
  color: #4a5899;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.orders-modal-page-btn:hover {
  background: rgba(237, 242, 255, 0.92);
  border-color: rgba(109, 136, 220, 0.85);
  color: #3f4f98;
  box-shadow: 0 8px 16px rgba(74, 88, 153, 0.12);
}

.orders-modal-page-btn.is-active {
  background: #4a5899;
  border-color: #4a5899;
  color: #ffffff;
  box-shadow: 0 10px 20px rgba(74, 88, 153, 0.24);
}

.orders-modal-page-btn.is-disabled {
  background: #f4f5fb;
  border-color: rgba(211, 217, 235, 0.95);
  color: #b0b7cf;
  box-shadow: none;
}

.orders-modal-page-arrow {
  padding: 0;
}

.orders-modal-page-ellipsis {
  min-width: 24px;
  text-align: center;
  color: #6f6a7f;
  font-size: 18px;
  font-weight: 700;
}

.order-detail-loading-state {
  margin: 0;
  text-align: center;
  padding: 28px 14px;
}

@media (max-width: 767px) {
  .orders-modal-pagination {
    align-items: flex-start;
    margin-top: 14px;
    margin-bottom: 16px;
    padding: 14px;
  }

  .orders-modal-pagination-actions {
    width: 100%;
    justify-content: flex-start;
    gap: 8px;
  }

  .orders-modal-pagination-status {
    width: 100%;
  }

  .orders-modal-page-btn {
    min-width: 36px;
    height: 36px;
    border-radius: 11px;
    padding: 0 10px;
    font-size: 13px;
  }
}

/* Operational load preview on the order form */
.order-operational-load-card {
  --load-preview-accent: #4a5899;
  background: rgba(255, 255, 255, 0.82);
}

.order-operational-load-card.is-low { --load-preview-accent: #3c9564; }
.order-operational-load-card.is-medium { --load-preview-accent: #a87917; }
.order-operational-load-card.is-high { --load-preview-accent: #c06a37; }
.order-operational-load-card.is-critical { --load-preview-accent: #b33f56; }

.order-operational-load-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 18px;
  align-items: stretch;
}

.order-operational-load-days {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.order-operational-load-day {
  --day-accent: #4a5899;
  appearance: none;
  display: grid;
  align-content: start;
  justify-items: center;
  gap: 5px;
  min-width: 0;
  padding: 12px 8px;
  border: 1px solid rgba(74, 88, 153, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  color: #29264a;
  font: inherit;
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.order-operational-load-day:hover {
  border-color: color-mix(in srgb, var(--day-accent) 34%, white);
  background: color-mix(in srgb, var(--day-accent) 3%, white);
}

.order-operational-load-day:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--day-accent) 42%, white);
  outline-offset: 2px;
}

.order-operational-load-day.is-selected {
  border-color: color-mix(in srgb, var(--day-accent) 58%, white);
  background: color-mix(in srgb, var(--day-accent) 6%, white);
  box-shadow: 0 7px 16px rgba(74, 88, 153, 0.08);
}

.order-operational-load-day.is-preview {
  border-color: color-mix(in srgb, var(--day-accent) 38%, white);
  background: color-mix(in srgb, var(--day-accent) 3%, white);
}

.order-operational-load-day.is-closed,
.order-operational-load-day.is-closed:hover {
  --day-accent: #8b91a6;
  cursor: default;
  border-color: rgba(139, 145, 166, 0.18);
  background: rgba(246, 247, 251, 0.92);
  box-shadow: none;
}

.order-operational-load-day.is-closed > i {
  background: #eef0f5;
}

.order-operational-load-day.is-closed > em {
  background: #eef0f5;
  color: #7a8197;
}

.order-operational-load-day.is-low { --day-accent: #3c9564; }
.order-operational-load-day.is-medium { --day-accent: #a87917; }
.order-operational-load-day.is-high { --day-accent: #c06a37; }
.order-operational-load-day.is-critical { --day-accent: #b33f56; }

.order-operational-load-day > span {
  color: #30305a;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.order-operational-load-day > small {
  color: #746e84;
  font-size: 0.72rem;
  line-height: 1.2;
}

.order-operational-load-day > i {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  width: 28px;
  height: 112px;
  margin: 5px 0 2px;
  padding: 4px;
  border-radius: 999px;
  background: #edf0f6;
  font-style: normal;
}

.order-operational-load-day > i > b {
  display: block;
  width: 100%;
  height: var(--load-progress, 0%);
  min-height: 4px;
  border-radius: 999px;
  background: var(--day-accent);
}

.order-operational-load-day > strong {
  color: #243d86;
  font-size: 1.15rem;
  line-height: 1.1;
}

.order-operational-load-day > em {
  padding: 4px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--day-accent) 12%, white);
  color: var(--day-accent);
  font-size: 0.68rem;
  font-style: normal;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
}

.order-operational-load-context {
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(74, 88, 153, 0.12);
  border-radius: 14px;
  background: rgba(248, 249, 255, 0.78);
  transition: background-color 160ms ease, border-color 160ms ease;
}

.order-operational-load-card.is-low .order-operational-load-context {
  border-color: rgba(60, 149, 100, 0.18);
  background: rgba(240, 250, 244, 0.76);
}

.order-operational-load-card.is-available .order-operational-load-context {
  border-color: rgba(41, 162, 107, 0.2);
  background: rgba(239, 250, 244, 0.84);
}

.order-operational-load-card.is-available .order-operational-load-context-heading > span {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #DCF7E8;
  color: #fff;
  border: 0;
  box-shadow: none;
}

.order-operational-load-card.is-available .order-operational-load-context-heading > span i {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 50%;
  background: #22B573;
  font-size: 0.72rem;
}

.order-operational-load-card.is-high .order-operational-load-context-heading > span {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 0;
  background: #FFE9C7;
  color: #fff;
  box-shadow: none;
}

.order-operational-load-card.is-high .order-operational-load-context-heading > span i {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 50%;
  background: #FF9D34;
  color: #fff;
  font-size: 0.72rem;
}

.order-operational-load-card.is-high .order-operational-load-status-pill {
  background: #FFE5C3;
  color: #D66D1F;
}

.order-operational-load-card.is-high .order-operational-load-context {
  border-color: rgba(192, 106, 55, 0.18);
  background: rgba(255, 248, 237, 0.8);
}

.order-operational-load-card.is-medium .order-operational-load-context {
  border-color: rgba(205, 164, 48, 0.24);
  background: rgba(255, 250, 232, 0.86);
}

.order-operational-load-card.is-medium .order-operational-load-context-heading > span {
  background: #fff0bd;
  color: #b98508;
}

.order-operational-load-card.is-medium .order-operational-load-status-pill {
  background: #fff0bd;
  color: #a87917;
}

.order-operational-load-card.is-critical .order-operational-load-context {
  border-color: rgba(179, 63, 86, 0.2);
  background: rgba(255, 241, 244, 0.8);
}

.order-operational-load-card.is-empty .order-operational-load-context {
  display: grid;
  align-content: center;
  justify-items: center;
  min-height: 190px;
  padding: 22px 24px;
  text-align: center;
}

.order-operational-load-card.is-empty .order-operational-load-context-heading {
  justify-content: center;
}

.order-operational-load-card.is-empty .order-operational-load-context-heading > div {
  justify-items: center;
}

.order-operational-load-card.is-empty .order-operational-load-context-heading {
  display: grid;
  justify-items: center;
  gap: 12px;
  margin-bottom: 0;
}

.order-operational-load-card.is-empty .order-operational-load-context-heading > span {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #e6efff;
  color: #2563c7;
}

.order-operational-load-card.is-empty .order-operational-load-context-heading strong {
  max-width: 220px;
  color: #163b91;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.35;
}

.order-operational-load-card.is-empty .order-operational-load-context > p[data-load-preview-summary] {
  max-width: 230px;
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid rgba(74, 88, 153, 0.14);
  color: #59658d;
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.55;
}

.order-operational-load-card.is-empty .order-operational-load-context > p[data-load-preview-detail] {
  display: none;
}

.order-operational-load-context[hidden] {
  display: none;
}

.order-operational-load-context-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 9px;
}

.order-operational-load-context-heading > span {
  display: inline-grid;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 9px;
  background: #eef0ff;
  color: #4a5899;
}

.order-operational-load-context-heading > span.is-critical {
  background: #fff0f2;
  color: #b33f56;
}

.order-operational-load-context-heading strong {
  color: var(--load-preview-accent);
  font-size: 0.82rem;
  line-height: 1.25;
}

.order-operational-load-context-heading > div {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.order-operational-load-status-pill {
  width: fit-content;
  padding: 4px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--load-preview-accent) 13%, white);
  color: var(--load-preview-accent);
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.1;
}

.order-operational-load-status-pill:empty {
  display: none;
}

.order-operational-load-context > p {
  margin: 0 0 5px;
  color: #5f5a71;
  font-size: 0.76rem;
  line-height: 1.4;
}

.order-operational-load-context > p[data-load-preview-summary] {
  color: #302d58;
  font-weight: 700;
}

.order-operational-load-details {
  margin-top: 14px;
  padding-top: 11px;
  border-top: 1px solid color-mix(in srgb, var(--load-preview-accent) 16%, white);
}

.order-operational-load-details > strong {
  display: block;
  margin-bottom: 8px;
  color: #302d58;
  font-size: 0.76rem;
}

.order-operational-load-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.order-operational-load-metrics > div {
  min-width: 0;
  padding: 0 10px;
  border-left: 1px solid rgba(74, 88, 153, 0.1);
}

.order-operational-load-metrics > div:first-child {
  padding-left: 0;
  border-left: 0;
}

.order-operational-load-metrics small,
.order-operational-load-metrics b,
.order-operational-load-metrics span {
  display: block;
}

.order-operational-load-metrics small {
  margin-bottom: 4px;
  color: #746e84;
  font-size: 0.66rem;
}

.order-operational-load-metrics b {
  color: #283d82;
  font-size: 0.76rem;
  line-height: 1.25;
}

.order-operational-load-metrics span {
  color: #746e84;
  font-size: 0.66rem;
  line-height: 1.25;
}

.order-operational-load-metric-suggestion {
  color: var(--load-preview-accent) !important;
  font-weight: 700;
}

.order-operational-load-card.is-available .order-operational-load-metric-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: #d8f4e4;
  color: #168451 !important;
  font-size: 0.68rem;
}

.order-operational-load-card.is-medium .order-operational-load-metric-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  max-width: 100%;
  padding: 5px 8px;
  border-radius: 999px;
  background: #d8f4e4;
  color: #168451 !important;
  font-size: 0.68rem;
  font-weight: 700;
  white-space: nowrap;
}

.order-operational-load-card.is-high .order-operational-load-metric-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  padding: 5px 7px;
  border-radius: 999px;
  background: #DDF6E7;
  color: #168451 !important;
  font-size: 0.62rem;
  font-weight: 700;
  white-space: nowrap;
}

.order-operational-load-card.is-high .order-operational-load-preview-suggestion > i,
.order-operational-load-card.is-high .order-operational-load-preview-suggestion-copy {
  display: none;
}

.order-operational-load-card.is-high .order-operational-load-preview-suggestion {
  grid-template-columns: minmax(0, 1fr);
  border-color: rgba(60, 149, 100, 0.2);
  background: transparent;
}

/* High-load state: match the approved warning panel composition. */
.order-operational-load-card.is-high .order-operational-load-context {
  padding: 16px 18px 15px;
  border-color: #f6d5b2;
  border-radius: 18px;
  background: #fff9f1;
}

.order-operational-load-card.is-high .order-operational-load-context-heading {
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
}

.order-operational-load-card.is-high .order-operational-load-context-heading > span {
  width: 48px;
  height: 48px;
  background: #ffe8c7;
  flex-basis: 48px;
}

.order-operational-load-card.is-high .order-operational-load-context-heading > span i {
  width: auto;
  height: auto;
  background: transparent;
  color: #ff7618;
  font-size: 2rem;
  line-height: 1;
}

.order-operational-load-card.is-high .order-operational-load-context-heading > div {
  gap: 6px;
  padding-top: 2px;
}

.order-operational-load-card.is-high .order-operational-load-context-heading strong {
  color: #c9361d;
  font-size: 1.22rem;
  line-height: 1.2;
}

.order-operational-load-card.is-high .order-operational-load-status-pill {
  padding: 8px 16px;
  background: #ffe5c3;
  color: #e34d16;
  font-size: 0.96rem;
}

.order-operational-load-card.is-high .order-operational-load-context > p[data-load-preview-summary] {
  max-width: 420px;
  margin: 0 0 12px;
  color: #596b91;
  font-size: 0.94rem;
  font-weight: 400;
  line-height: 1.5;
}

.order-operational-load-card.is-high .order-operational-load-details {
  margin-top: 0;
  padding-top: 12px;
  border-top-color: #f3d2ad;
}

.order-operational-load-card.is-high .order-operational-load-details > strong {
  margin-bottom: 10px;
  color: #173c87;
  font-size: 1rem;
}

.order-operational-load-card.is-high .order-operational-load-metrics {
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr) minmax(0, 1.5fr);
}

.order-operational-load-card.is-high .order-operational-load-metrics > div {
  min-height: 58px;
  padding: 0 10px;
  border-left-color: #f3d2ad;
}

.order-operational-load-card.is-high .order-operational-load-metrics > div:first-child {
  padding-left: 0;
}

.order-operational-load-card.is-high .order-operational-load-metrics small {
  margin-bottom: 8px;
  color: #66799f;
  font-size: 0.8rem;
}

.order-operational-load-card.is-high .order-operational-load-metrics b {
  color: #153b89;
  font-size: 1.05rem;
}

.order-operational-load-card.is-high .order-operational-load-metrics span {
  color: #66799f;
  font-size: 0.76rem;
}

.order-operational-load-card.is-high .order-operational-load-metric-suggestion {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: fit-content;
  max-width: 100%;
  padding: 6px 9px;
  border-radius: 999px;
  background: #dff6e8;
  color: #178754 !important;
  font-size: 0.72rem;
  white-space: nowrap;
}

.order-operational-load-card.is-high .order-operational-load-metric-suggestion i {
  font-size: 0.85rem;
}

.order-operational-load-card.is-high .order-operational-load-preview-suggestion {
  display: block;
  margin-top: 22px;
  padding: 0;
  border: 0;
  background: transparent;
}

.order-operational-load-card.is-high .order-operational-load-preview-suggestion .btn {
  min-height: 48px;
  padding: 12px 18px;
  border: 1px solid #159b61;
  border-radius: 10px;
  background: #159b61;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
}

@media (max-width: 767px) {
  .order-operational-load-card.is-high .order-operational-load-context {
    padding: 14px;
  }

  .order-operational-load-card.is-high .order-operational-load-context-heading > span {
    width: 48px;
    height: 48px;
    flex-basis: 48px;
  }

  .order-operational-load-card.is-high .order-operational-load-context-heading > span i {
    font-size: 2rem;
  }

  .order-operational-load-card.is-high .order-operational-load-context-heading strong {
    font-size: 1rem;
  }

  .order-operational-load-card.is-high .order-operational-load-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .order-operational-load-card.is-high .order-operational-load-metrics > div {
    padding: 0 10px;
  }

  .order-operational-load-card.is-high .order-operational-load-metrics > div:nth-child(3) {
    grid-column: 1 / -1;
    padding-left: 0;
    border-left: 0;
  }
}

.order-operational-load-context > p[data-load-preview-remaining] {
  margin-top: 8px;
  color: #4e6b5d;
}

.order-operational-load-context .order-operational-load-preview-suggestion {
  margin-top: 12px;
  border-color: rgba(60, 149, 100, 0.2);
  background: rgba(240, 250, 244, 0.76);
  grid-template-columns: 28px minmax(0, 1fr);
}

.order-operational-load-context .order-operational-load-preview-suggestion .btn {
  grid-column: 1 / -1;
  width: 100%;
  border-color: #249b68;
  background: #249b68;
  color: #fff;
}

.order-operational-load-context .order-operational-load-preview-actions {
  margin-top: 10px;
}

@media (max-width: 899px) {
  .order-operational-load-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .order-operational-load-days {
    display: flex;
    gap: 9px;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
  }

  .order-operational-load-day {
    flex: 0 0 104px;
    scroll-snap-align: start;
  }

  .order-operational-load-context {
    padding: 12px;
  }

  .order-operational-load-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 0;
  }

  .order-operational-load-metrics > div:nth-child(3) {
    grid-column: 1 / -1;
    padding-left: 0;
    border-left: 0;
  }
}

/* Orders modals: keep results scrollable and pagination visually stable. */
#allOrdersModal .modal-body,
#allOrdersModal .all-orders-modal-body,
#otherPendingOrdersModal .modal-body,
#otherPendingOrdersModal .pending-orders-modal-body,
#otherPendingOrdersModal .delayed-orders-modal-body {
  display: flex !important;
  flex-direction: column !important;
  min-height: 0 !important;
  overflow: hidden !important;
  padding-bottom: 16px !important;
}

#allOrdersModal .all-orders-desktop-results,
#allOrdersModal .orders-total-table-shell,
#allOrdersModal .table-wrapper.orders-total-table-shell,
#allOrdersModal .all-orders-mobile-results,
#allOrdersModal .orders-modal-results-mobile,
#otherPendingOrdersModal .pending-orders-desktop-results,
#otherPendingOrdersModal .delayed-orders-table-shell,
#otherPendingOrdersModal .pending-orders-mobile-results {
  flex: 1 1 auto !important;
  min-height: 420px;
  min-width: 0;
  scrollbar-gutter: stable;
}

#allOrdersModal .all-orders-desktop-results,
#allOrdersModal .orders-total-table-shell,
#allOrdersModal .table-wrapper.orders-total-table-shell,
#otherPendingOrdersModal .pending-orders-desktop-results,
#otherPendingOrdersModal .delayed-orders-table-shell {
  overflow-x: auto !important;
  overflow-y: auto !important;
}

#allOrdersModal .all-orders-desktop-results,
#allOrdersModal .orders-total-table-shell,
#allOrdersModal .table-wrapper.orders-total-table-shell {
  overflow-y: visible !important;
  position: relative;
  z-index: 1;
}

#allOrdersModal .all-orders-mobile-results,
#allOrdersModal .orders-modal-results-mobile,
#otherPendingOrdersModal .pending-orders-mobile-results {
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding-right: 4px;
}

#allOrdersModal .history-empty-state[data-orders-total-empty-state],
#otherPendingOrdersModal .history-empty-state[data-pending-other-empty-state] {
  flex-shrink: 0;
  margin-top: 12px;
  margin-bottom: 16px;
}

#allOrdersModal.is-empty-results .all-orders-desktop-results,
#allOrdersModal.is-empty-results .orders-total-table-shell,
#allOrdersModal.is-empty-results .table-wrapper.orders-total-table-shell,
#allOrdersModal.is-empty-results .all-orders-mobile-results,
#allOrdersModal.is-empty-results .orders-modal-results-mobile {
  display: none !important;
}

.orders-modal-empty-state {
  width: 100%;
  padding: 24px 0 12px;
  opacity: 1;
}

.orders-modal-empty-state-card {
  width: min(100%, 560px);
  margin: 0 auto;
  padding: 28px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

.orders-modal-empty-state-icon {
  width: 48px;
  height: 48px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  background: var(--panel-surface);
  color: var(--primary);
  font-size: 22px;
}

.orders-modal-empty-state-title {
  margin: 0;
  color: var(--text);
  font-size: 1.15rem;
  line-height: 1.3;
}

.orders-modal-empty-state-copy {
  margin: 0;
  max-width: 44ch;
  color: var(--muted);
  line-height: 1.55;
}

.orders-modal-empty-state-action {
  margin-top: 4px;
}

@media (max-width: 768px) {
  .orders-modal-empty-state {
    padding-top: 18px;
  }

  .orders-modal-empty-state-card {
    width: 100%;
    padding: 24px 18px;
  }

  .orders-modal-empty-state-action {
    width: 100%;
  }
}

@media (max-width: 1024px) {
  #allOrdersModal .all-orders-desktop-results,
  #allOrdersModal .orders-total-table-shell,
  #allOrdersModal .table-wrapper.orders-total-table-shell,
  #allOrdersModal .all-orders-mobile-results,
  #allOrdersModal .orders-modal-results-mobile,
  #otherPendingOrdersModal .pending-orders-desktop-results,
  #otherPendingOrdersModal .delayed-orders-table-shell,
  #otherPendingOrdersModal .pending-orders-mobile-results {
    min-height: 320px;
  }
}

/* FIX GLOBAL CONTROLADO:
   Evita que la paginacion suba/baje segun la cantidad de filas
   Aplica solo a:
   - Todas las ordenes
   - Ordenes pendientes de entrega
*/

/* Modal mas amplio y estable */
#allOrdersModal .modal-dialog.modal-content.modal-orders-wide,
#otherPendingOrdersModal .modal-dialog.modal-content.delayed-orders-modal.orders-modal-standard {
  width: 96vw !important;
  max-width: 1500px !important;
  height: 94vh !important;
  max-height: 94vh !important;

  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

/* El body ocupa todo el alto restante del modal */
#allOrdersModal .modal-body,
#otherPendingOrdersModal .delayed-orders-modal-body {
  flex: 1 1 auto !important;
  min-height: 0 !important;

  display: flex !important;
  flex-direction: column !important;
  overflow: hidden !important;
}

/* Filtros arriba, sin crecer */
#allOrdersModal .orders-total-filters,
#otherPendingOrdersModal .history-filters,
#otherPendingOrdersModal .pending-other-filters {
  flex: 0 0 auto !important;
}

/* La tabla ocupa siempre el espacio libre, aunque haya pocas filas */
#allOrdersModal .table-container,
#allOrdersModal .orders-total-table-shell,
#otherPendingOrdersModal .delayed-orders-table-shell {
  flex: 1 1 0 !important;
  min-height: 420px !important;
  height: auto !important;
  max-height: none !important;

  overflow-x: auto !important;
  overflow-y: auto !important;
}

/* La tabla no define la altura del modal */
#allOrdersModal .table-wrapper,
#otherPendingOrdersModal .table-wrapper {
  min-height: 100% !important;
}

/* La paginacion queda anclada abajo */
#allOrdersModal .orders-modal-pagination,
#otherPendingOrdersModal .orders-modal-pagination {
  flex: 0 0 auto !important;
  margin-top: 16px !important;
  margin-bottom: 0 !important;
}

/* Fase 3A - Apariencia del sistema */
.appearance-page-shell {
  display: grid;
  gap: var(--section-gap, 18px);
}

.appearance-intro-card,
.appearance-preview-workspace,
.appearance-coming-soon-card {
  overflow: hidden;
}

.appearance-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--secondary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.appearance-theme-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.appearance-preview-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.appearance-theme-chip {
  border: 1px solid var(--color-button-outline-border);
  background: var(--color-button-outline-bg);
  color: var(--primary);
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.appearance-theme-chip:hover {
  background: var(--color-button-outline-hover-bg);
  transform: translateY(-1px);
}

.appearance-theme-chip.is-active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
  box-shadow: var(--shadow-button-primary-strong);
}

.appearance-live-preview-shell {
  display: grid;
  gap: var(--component-gap, 14px);
  margin-top: 20px;
}

.appearance-live-preview-copy {
  display: grid;
  gap: 6px;
}

.appearance-live-preview-title {
  margin: 0;
  color: var(--color-title);
  font-size: clamp(22px, calc(3vw * var(--title-scale, 1)), calc(28px * var(--title-scale, 1)));
  font-weight: var(--heading-font-weight, 700);
  line-height: 1.15;
}

.appearance-live-preview-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  max-width: 720px;
}

.appearance-live-preview,
.appearance-mini-preview {
  background: var(--app-background);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  color: var(--text);
}

.appearance-live-preview {
  padding: 18px;
}

.appearance-demo-topbar,
.appearance-mini-preview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.appearance-demo-topbar {
  padding: 18px;
  margin-bottom: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow-soft);
}

.appearance-demo-topbar-copy,
.appearance-mini-preview-card {
  display: grid;
  gap: var(--component-gap, 8px);
}

.appearance-demo-title {
  color: var(--color-title);
  font-size: calc(28px * var(--title-scale, 1));
  font-weight: var(--heading-font-weight, 700);
  line-height: 1.1;
}

.appearance-demo-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.appearance-demo-badge {
  display: inline-flex;
  min-width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--color-notification-badge-bg);
  color: var(--color-notification-badge-text);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  box-shadow: var(--shadow-soft);
}

.appearance-demo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--section-gap, 16px);
}

.appearance-demo-card,
.appearance-mini-preview-card,
.appearance-demo-mini-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow-soft);
}

.appearance-demo-card {
  display: grid;
  gap: var(--card-gap, 14px);
  padding: var(--card-padding, 18px);
}

.appearance-demo-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--component-gap, 10px);
}

body.has-custom-theme-overrides .btn:not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.order-detail-header-void-btn),
.appearance-page-shell .btn:not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary),
.appearance-modal .btn:not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary),
.appearance-live-preview .btn:not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary),
body.has-custom-theme-overrides .btn-secondary-action-outline:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn),
body.has-custom-theme-overrides .btn-secondary-action-ghost,
body.has-custom-theme-overrides .btn-outline-primary {
  border-radius: var(--button-radius, var(--radius-sm));
  padding: var(--button-padding-y, 13px) var(--button-padding-x, 24px);
  font-size: var(--button-font-size, 0.95rem);
  box-shadow: var(--button-shadow, var(--shadow-button));
}

body.has-custom-theme-overrides .btn-secondary-action-outline:not(.order-detail-whatsapp-link):not(.whatsapp-quick-trigger):not(.search-whatsapp-action):not(.orders-whatsapp-action-btn),
body.has-custom-theme-overrides .btn-secondary-action-ghost,
body.has-custom-theme-overrides .btn-outline-primary {
  box-shadow: none;
}

body.has-custom-theme-overrides .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.order-detail-header-void-btn),
.appearance-page-shell .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary),
.appearance-modal .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary),
.appearance-live-preview .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary) {
  background: var(--button-primary-bg, var(--color-button-primary));
  color: var(--button-primary-color, var(--white));
  border: 1px solid var(--button-primary-border, transparent);
}

body.has-custom-theme-overrides .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.order-detail-header-void-btn):hover,
.appearance-page-shell .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary):hover,
.appearance-modal .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary):hover,
.appearance-live-preview .btn:not(.btn-secondary):not(.btn-danger):not(.is-danger):not(.btn-ghost):not(.btn-secondary-action-outline):not(.btn-secondary-action-ghost):not(.btn-outline-primary):not(.secondary-top-action-btn):not(.orders-secondary-action-btn):not(.mobile-view-all-button):not(.appearance-demo-btn-tertiary):hover {
  background: var(--button-primary-hover-bg, var(--color-button-primary-hover));
}

body.has-custom-theme-overrides .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost),
.appearance-page-shell .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost),
.appearance-modal .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost),
.appearance-live-preview .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost) {
  background: var(--button-secondary-bg, var(--color-button-secondary));
  color: var(--button-secondary-color, var(--white));
  border: 1px solid var(--button-secondary-border, transparent);
}

body.has-custom-theme-overrides .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost):hover,
.appearance-page-shell .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost):hover,
.appearance-modal .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost):hover,
.appearance-live-preview .btn.btn-secondary:not(.btn-danger):not(.is-danger):not(.btn-ghost):hover {
  background: var(--button-secondary-hover-bg, var(--color-button-secondary-hover));
}

.appearance-page-shell .btn.btn-secondary-action-outline,
.appearance-modal .btn.btn-secondary-action-outline,
.appearance-live-preview .btn.btn-secondary-action-outline,
.appearance-page-shell .appearance-demo-btn-tertiary,
.appearance-modal .appearance-demo-btn-tertiary,
.appearance-live-preview .appearance-demo-btn-tertiary {
  background: var(--color-button-tertiary-bg, #ffffff);
  color: var(--color-button-tertiary-text, var(--color-button-primary));
  border: 1px solid var(--color-button-tertiary-border, var(--color-button-outline-border));
  border-radius: var(--button-radius, var(--radius-sm));
  padding: var(--button-padding-y, 13px) var(--button-padding-x, 24px);
  font-size: var(--button-font-size, 0.95rem);
  box-shadow: none;
}

.appearance-page-shell .btn.btn-secondary-action-outline:hover,
.appearance-modal .btn.btn-secondary-action-outline:hover,
.appearance-live-preview .btn.btn-secondary-action-outline:hover,
.appearance-page-shell .appearance-demo-btn-tertiary:hover,
.appearance-modal .appearance-demo-btn-tertiary:hover,
.appearance-live-preview .appearance-demo-btn-tertiary:hover {
  background: var(--color-button-tertiary-hover, var(--color-surface-soft));
  color: var(--color-button-tertiary-text, var(--color-button-primary));
  border-color: var(--color-button-tertiary-border, var(--color-button-primary));
}

.appearance-page-shell .btn.btn-secondary-action-outline i,
.appearance-modal .btn.btn-secondary-action-outline i,
.appearance-live-preview .btn.btn-secondary-action-outline i,
.appearance-page-shell .appearance-demo-btn-tertiary i,
.appearance-modal .appearance-demo-btn-tertiary i,
.appearance-live-preview .appearance-demo-btn-tertiary i {
  color: currentColor;
}

body.has-custom-theme-overrides .btn.expense-cash-box-submit {
  background: var(--button-primary-bg, var(--color-button-primary));
  color: var(--button-primary-color, var(--color-button-primary-color, #fff));
  border: 1px solid var(--button-primary-border, var(--color-button-primary, var(--color-primary)));
  box-shadow: var(--button-shadow, var(--shadow-button));
}

body.has-custom-theme-overrides .btn.expense-cash-box-submit:hover,
body.has-custom-theme-overrides .btn.expense-cash-box-submit:focus-visible {
  background: var(--button-primary-hover-bg, var(--color-button-primary-hover));
  color: var(--button-primary-color, var(--color-button-primary-color, #fff));
  border-color: var(--button-primary-hover-bg, var(--color-button-primary-hover));
}

body.has-custom-theme-overrides .btn.expense-cash-box-submit:active {
  background: var(--button-primary-hover-bg, var(--color-button-primary-hover));
  color: var(--button-primary-color, var(--color-button-primary-color, #fff));
  border-color: var(--button-primary-hover-bg, var(--color-button-primary-hover));
}

body.has-custom-theme-overrides .btn.expense-cash-box-submit:disabled,
body.has-custom-theme-overrides .btn.expense-cash-box-submit[disabled] {
  color: var(--button-primary-color, var(--color-button-primary-color, #fff));
}

body.has-custom-theme-overrides .btn.expense-cash-box-submit i,
body.has-custom-theme-overrides .btn.expense-cash-box-submit .fa,
body.has-custom-theme-overrides .btn.expense-cash-box-submit .fa-solid {
  color: currentColor !important;
}

.appearance-demo-button {
  gap: 10px;
}

.appearance-demo-button-icon {
  display: none;
  font-size: 0.88em;
  line-height: 1;
}

.appearance-live-preview[data-button-icon-mode="left"] .appearance-demo-button-icon--left,
.appearance-live-preview[data-button-icon-mode="right"] .appearance-demo-button-icon--right {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.appearance-demo-field {
  margin: 0;
}

.appearance-demo-mini-card {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  background: var(--panel-surface);
}

.appearance-demo-mini-card .section-subtitle {
  margin: 0;
}

.appearance-preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.appearance-preset-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.appearance-preset-card:hover {
  transform: translateY(-2px);
  border-color: var(--color-button-outline-border);
  box-shadow: var(--shadow);
}

.appearance-preset-card:focus-visible {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--color-focus-ring), var(--shadow);
}

.appearance-preset-card.is-active {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary), var(--shadow);
  background: var(--panel-surface);
}

.appearance-preset-card.is-active .appearance-preset-code,
.appearance-preset-card.is-active .appearance-preset-tag {
  border-color: var(--primary);
  background: var(--color-button-outline-hover-bg);
}

.appearance-preset-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.appearance-preset-card-head h4 {
  margin: 6px 0 0;
  color: var(--color-title);
  font-size: 18px;
  line-height: 1.2;
}

.appearance-preset-code,
.appearance-preset-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 6px 10px;
  background: var(--color-surface-soft);
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid var(--line);
}

.appearance-preset-tag {
  white-space: nowrap;
}

.appearance-preset-description {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.appearance-swatch-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.appearance-swatch-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.appearance-swatch-chip {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.appearance-mini-preview {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.appearance-mini-preview-card {
  padding: 14px;
}

.appearance-mini-preview-card input {
  margin-top: 10px;
}

.appearance-coming-soon-grid {
  display: grid;
  gap: 14px;
  margin-top: 6px;
}

.appearance-coming-soon-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--card);
  border: 1px dashed var(--line);
  border-radius: 20px;
}

.appearance-coming-soon-item i {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--secondary);
  font-size: 18px;
}

.appearance-coming-soon-item strong {
  display: block;
  color: var(--color-title);
  margin-bottom: 4px;
}

.appearance-coming-soon-item p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.appearance-coming-soon-item span:last-child {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.appearance-coming-soon-item.is-disabled {
  opacity: 0.82;
}

@media (max-width: 1024px) {
  .appearance-demo-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .appearance-theme-selector {
    gap: 8px;
  }

  .appearance-theme-chip {
    width: 100%;
    justify-content: center;
  }

  .appearance-demo-topbar,
  .appearance-preset-card-head {
    flex-direction: column;
  }

  .appearance-coming-soon-item {
    grid-template-columns: 1fr;
    justify-items: flex-start;
  }

  .appearance-demo-title {
    font-size: 24px;
  }

  .appearance-live-preview,
  .appearance-preset-card,
  .appearance-demo-card {
    padding: 16px;
  }
}

/* Fase 3A.2 - Refinamiento visual */
.appearance-page-shell {
  gap: 22px;
}

.appearance-notice-band,
.appearance-selector-card,
.appearance-preview-workspace,
.appearance-library-card,
.appearance-coming-soon-card {
  position: relative;
}

.appearance-notice-band {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 18px 20px;
  background: var(--panel-surface);
}

.appearance-notice-band__icon {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-soft);
  color: var(--secondary);
  box-shadow: var(--shadow-soft);
  font-size: 20px;
}

.appearance-notice-band__copy {
  display: grid;
  gap: 6px;
}

.appearance-notice-band__copy .section-title {
  margin: 0;
  font-size: clamp(20px, 2.2vw, 24px);
  line-height: 1.2;
}

.appearance-notice-band__copy .section-subtitle {
  margin: 0;
  max-width: 820px;
}

.appearance-notice-band__accent {
  display: grid;
  gap: 8px;
  justify-items: end;
}

.appearance-notice-band__accent span {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--surface-soft), transparent);
}

.appearance-notice-band__accent span:first-child {
  width: 90px;
}

.appearance-notice-band__accent span:last-child {
  width: 54px;
}

.appearance-selector-card,
.appearance-preview-workspace,
.appearance-library-card,
.appearance-coming-soon-card {
  padding: 20px;
}

.appearance-selector-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 4px;
}

.appearance-selector-option {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.appearance-selector-option:hover {
  transform: translateY(-1px);
  border-color: var(--color-button-outline-border);
}

.appearance-selector-option.is-active {
  border-color: var(--primary);
  background: var(--panel-surface);
  box-shadow: 0 0 0 1px var(--primary), var(--shadow-soft);
}

.appearance-selector-option__swatch {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
}

.appearance-selector-option__copy {
  display: grid;
  gap: 3px;
  text-align: left;
}

.appearance-selector-option__copy strong {
  color: var(--color-title);
  font-size: 14px;
  line-height: 1.2;
}

.appearance-selector-option__copy small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
}

.appearance-selector-option__check {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-soft);
  color: transparent;
  border: 1px solid var(--line);
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.appearance-selector-option.is-active .appearance-selector-option__check {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.appearance-preview-note {
  margin-top: 12px;
}

.appearance-preview-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.appearance-preview-theme-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.appearance-preview-control-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  align-items: center;
  gap: 18px;
  padding: 14px 16px;
  margin: 14px 0 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: color-mix(in srgb, var(--panel-surface) 86%, white 14%);
  box-shadow: var(--shadow-soft);
}

.appearance-preview-control-left {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  min-width: 0;
}

.appearance-current-theme-label {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.3;
}

.appearance-preview-control-right {
  display: grid;
  justify-items: end;
  align-items: center;
  gap: 6px;
  min-width: max-content;
  justify-self: end;
}

.appearance-preview-buttons {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: nowrap;
  width: auto;
}

.appearance-inline-form {
  margin: 0;
}

.appearance-preview-buttons .appearance-inline-form,
.appearance-preview-buttons form,
.appearance-preview-buttons .appearance-actions-row {
  display: inline-flex;
  width: auto;
  margin: 0;
  flex: 0 0 auto;
}

.appearance-save-state {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  width: fit-content;
  padding: 7px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel-surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.appearance-save-state i {
  color: var(--primary);
}

.appearance-save-state.is-dirty {
  border-color: var(--secondary);
  background: var(--color-button-outline-hover-bg);
  color: var(--secondary);
}

.appearance-save-state.is-dirty i {
  color: var(--secondary);
}

.appearance-actions-row {
  display: flex;
  gap: 0;
  align-items: center;
  margin-top: 0;
}

.appearance-preview-buttons .btn {
  width: auto;
  min-width: max-content;
  min-height: 42px;
  white-space: nowrap;
}

.appearance-page-shell .btn.is-loading,
.appearance-modal .btn.is-loading {
  opacity: 0.88;
  cursor: wait;
  pointer-events: none;
}

.appearance-page-shell .btn.is-loading,
.appearance-modal .btn.is-loading {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.appearance-loading-spinner {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  flex-shrink: 0;
  animation: appearance-loading-spin 0.72s linear infinite;
}

@keyframes appearance-loading-spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.appearance-reset-btn {
  background: var(--color-button-outline-bg);
  color: var(--primary);
  border: 1px solid var(--color-button-outline-border);
  box-shadow: var(--shadow-soft);
}

.appearance-reset-btn:hover {
  background: var(--color-button-outline-hover-bg);
}

.appearance-actions-helper {
  margin: 0;
  max-width: 360px;
  font-size: 12px;
  color: var(--muted);
  text-align: right;
}

.appearance-live-preview {
  padding: 22px;
}

.appearance-demo-chrome {
  margin-bottom: 16px;
}

.appearance-demo-topbar {
  margin-bottom: 0;
}

.appearance-demo-stage {
  display: grid;
  gap: var(--section-gap, 16px);
}

.appearance-demo-hero-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--component-gap, 18px);
  padding: var(--card-padding, 22px);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
}

.appearance-demo-hero-card__copy {
  display: grid;
  gap: var(--component-gap, 8px);
  max-width: 640px;
}

.appearance-demo-hero-card__copy .section-title,
.appearance-demo-card .section-title {
  margin: 0;
}

.appearance-demo-hero-card__copy .section-subtitle,
.appearance-demo-card .section-subtitle {
  margin: 0;
}

.appearance-demo-support-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--section-gap, 16px);
}

.appearance-demo-card {
  padding: var(--card-padding, 18px);
}

.appearance-demo-card--soft {
  align-content: start;
  background: var(--card-surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}

.appearance-demo-inline-pill {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: var(--color-badge-bg, var(--surface-soft));
  color: var(--color-badge-text, var(--primary));
  border: 1px solid var(--color-badge-border, var(--line));
  font-size: 12px;
  font-weight: 700;
}

.appearance-system-preview {
  display: grid;
  gap: 0;
}

.appearance-system-preview__header-shell {
  margin-bottom: var(--component-gap, 12px);
}

.appearance-system-preview__hero-badge {
  min-width: 32px;
  height: 32px;
  padding: 0 9px;
  background: var(--color-badge-bg, var(--surface-soft));
  color: var(--color-badge-text, var(--primary));
  border: 1px solid var(--color-badge-border, var(--line));
  box-shadow: var(--shadow-soft);
}

.appearance-system-preview__content {
  display: grid;
  gap: var(--section-gap, 12px);
}

.appearance-system-preview__card {
  align-items: center;
}

.appearance-system-preview__card-copy {
  max-width: 620px;
}

.appearance-system-preview__actions {
  justify-content: flex-end;
}

@media (max-width: 1180px) and (min-width: 768px) {
  .tablet-app-mode .appearance-live-preview .appearance-demo-actions:not(.appearance-system-preview__actions),
  .appearance-live-preview .appearance-demo-actions:not(.appearance-system-preview__actions) {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 12px !important;
    width: 100% !important;
    align-items: stretch !important;
    justify-items: stretch !important;
    justify-content: stretch !important;
  }

  .tablet-app-mode .appearance-live-preview .appearance-demo-actions:not(.appearance-system-preview__actions) .btn,
  .appearance-live-preview .appearance-demo-actions:not(.appearance-system-preview__actions) .btn {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    min-height: 44px !important;
    justify-content: center !important;
    align-self: stretch !important;
    margin: 0 !important;
    white-space: nowrap;
  }

  .tablet-app-mode .appearance-system-preview__actions.appearance-demo-actions,
  .appearance-system-preview__actions.appearance-demo-actions {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    justify-items: stretch !important;
    gap: 12px !important;
    width: 100% !important;
  }

  .tablet-app-mode .appearance-modal .appearance-system-preview__actions.appearance-demo-actions .appearance-demo-button,
  .tablet-app-mode .appearance-page-shell .appearance-system-preview__actions.appearance-demo-actions .appearance-demo-button,
  .appearance-system-preview__actions.appearance-demo-actions .appearance-demo-button {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    justify-content: center !important;
    align-self: stretch !important;
    min-height: 44px !important;
    white-space: nowrap;
    margin: 0 !important;
  }

  .tablet-app-mode .appearance-system-preview__actions.appearance-demo-actions .appearance-demo-button--tertiary,
  .appearance-system-preview__actions.appearance-demo-actions .appearance-demo-button--tertiary {
    align-self: stretch !important;
    margin: 0 !important;
  }
}

.appearance-system-preview__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--section-gap, 12px);
  align-items: stretch;
}

.appearance-system-preview__form,
.appearance-system-preview__modal,
.appearance-system-preview__table-card {
  padding: var(--card-padding, 16px);
}

.appearance-system-preview__form {
  align-content: start;
}

.appearance-system-preview__modal {
  display: grid;
  gap: var(--card-gap, 10px);
  align-content: start;
  background: var(--card-surface);
}

.appearance-system-preview__modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--component-gap, 10px);
  flex-wrap: wrap;
}

.appearance-system-preview__table-card {
  display: grid;
  gap: var(--card-gap, 10px);
  background: var(--card-surface);
}

.appearance-system-preview__segments-card {
  display: grid;
  gap: var(--card-gap, 10px);
  background: var(--card-surface);
}

.appearance-system-preview__segments-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--component-gap, 10px);
}

.appearance-system-preview__segments {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  overflow-x: auto;
  overflow-y: hidden;
}

.appearance-system-preview__segment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--color-segmented-border, #D9E6EF);
  background: var(--color-segmented-bg, #FFFFFF);
  color: var(--color-segmented-text, var(--color-title));
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.appearance-system-preview__segment:not(.appearance-system-preview__segment--active):hover {
  background: var(--color-segmented-hover-bg, var(--color-surface-soft));
  color: var(--color-segmented-text, var(--color-title));
  border-color: var(--color-segmented-border, #D9E6EF);
}

.appearance-system-preview__segment--active,
.appearance-system-preview__segment--active:hover,
.appearance-system-preview__segment--active:focus-visible {
  background: var(--color-segmented-active-bg, var(--color-primary));
  color: var(--color-segmented-active-text, #FFFFFF);
  border-color: var(--color-segmented-active-bg, var(--color-primary));
  box-shadow: none;

}

.appearance-system-preview__segment--active::before,
.appearance-system-preview__segment--active::after {
  display: none;
  content: none;
}

.appearance-system-preview__table-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--component-gap, 10px);
}

.appearance-system-preview__table-header .section-title,
.appearance-system-preview__table-card .section-subtitle {
  margin: 0;
}

.appearance-system-preview__table-action {
  min-width: 0;
  white-space: nowrap;
}

.appearance-system-preview__table-shell {
  overflow-x: auto;
  overflow-y: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: color-mix(in srgb, var(--card) 92%, white 8%);
  box-shadow: var(--shadow-soft);
}

.appearance-system-preview__table {
  width: 100%;
  border-collapse: collapse;
  min-width: 500px;
}

.appearance-system-preview__table th,
.appearance-system-preview__table td {
  padding: 10px 12px;
  text-align: left;
  font-size: 12px;
  vertical-align: middle;
}

.appearance-system-preview__table th {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: color-mix(in srgb, var(--card) 88%, white 12%);
}

.appearance-system-preview__table tbody tr + tr td,
.appearance-system-preview__table-row + .appearance-system-preview__table-row td {
  border-top: 1px solid var(--line);
}

.appearance-system-preview__table-row td {
  background: color-mix(in srgb, var(--card) 97%, transparent);
}

.appearance-system-preview__table td:first-child,
.appearance-system-preview__table td:nth-child(2) {
  color: var(--color-title);
  font-weight: 700;
}

.appearance-system-preview__pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 5px 9px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.appearance-system-preview__pill--pending {
  background: #fff3cd;
  color: #9a6700;
  border-color: #f2d38b;
}

.appearance-system-preview__pill--success {
  background: #dcfce7;
  color: #1f7a4c;
  border-color: #b7e7ca;
}

.appearance-system-preview__pill--info {
  background: #e4e6fb;
  color: #4a5899;
  border-color: #cfd4f7;
}

.appearance-system-preview__pill--ready {
  background: #e0f2fe;
  color: #235f9f;
  border-color: #bfe2fb;
}

.appearance-system-preview__pill--warning {
  background: #fff0db;
  color: #a45300;
  border-color: #f5cf9a;
}

.appearance-system-preview__pill--neutral {
  background: #eef1f6;
  color: #5e6776;
  border-color: #d8dee8;
}

.appearance-system-preview__action-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--color-button-tertiary-border, var(--line)) 72%, white 28%);
  background: color-mix(in srgb, var(--color-button-tertiary-bg, var(--card)) 84%, white 16%);
  color: var(--color-button-tertiary-text, var(--color-title));
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.48);
}

.appearance-system-preview__action-dot i,
.appearance-system-preview__action-dot .fa,
.appearance-system-preview__action-dot .fa-solid {
  color: currentColor;
}

@media (max-width: 1200px) {
  .appearance-system-preview__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 767px) {
  .appearance-system-preview__card,
  .appearance-system-preview__table-header,
  .appearance-system-preview__modal-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .appearance-system-preview__actions {
    width: 100%;
    justify-content: flex-start;
  }

  .appearance-system-preview__actions .btn,
  .appearance-system-preview__modal-footer .btn {
    width: 100%;
  }

  .appearance-system-preview__table-shell {
    overflow-x: auto;
  }

  .appearance-system-preview__table {
    min-width: 560px;
  }
}

.appearance-library-card .section-header,
.appearance-branding-card .section-header,
.appearance-coming-soon-card .section-header {
  margin-bottom: 16px;
}

.appearance-branding-form {
  display: grid;
  gap: 16px;
}

.appearance-branding-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.appearance-branding-card .form-group {
  margin-bottom: 0;
}

.appearance-branding-card .helper-text {
  margin-top: 8px;
}

.appearance-branding-actions {
  display: flex;
  justify-content: flex-end;
}

.appearance-custom-theme-card .section-header {
  margin-bottom: 16px;
}

.appearance-custom-theme-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel-surface);
  box-shadow: var(--shadow-soft);
}

.appearance-custom-theme-status .section-title {
  margin: 4px 0 0;
  font-size: 18px;
}

.appearance-custom-themes-card .section-header {
  margin-bottom: 16px;
}

.appearance-custom-theme-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  align-items: stretch;
}

.appearance-custom-theme-list-compact {
  grid-template-columns: 1fr;
}

.appearance-custom-theme-item {
  display: grid;
  gap: 12px;
  min-height: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
}

.appearance-custom-theme-item.is-active {
  border-color: var(--primary);
  background: var(--panel-surface);
}

.appearance-custom-theme-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(200px, 0.75fr) auto;
  gap: 14px;
  align-items: start;
}

.appearance-custom-theme-info {
  display: grid;
  gap: 10px;
}

.appearance-custom-theme-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.appearance-custom-theme-copy {
  display: grid;
  gap: 6px;
}

.appearance-custom-theme-copy h4,
.appearance-custom-theme-copy p {
  margin: 0;
}

.appearance-custom-theme-copy p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.appearance-custom-theme-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}

.appearance-custom-theme-base-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--panel-surface);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.appearance-custom-theme-swatches {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.appearance-custom-theme-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.appearance-custom-theme-helper {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  max-width: 240px;
}

.appearance-custom-theme-actions-menu {
  display: grid;
  gap: 10px;
  justify-items: end;
  align-content: start;
}

.appearance-custom-theme-secondary-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.appearance-custom-theme-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.appearance-custom-theme-updated {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.appearance-custom-theme-edit {
  margin-top: 8px;
  border-top: 1px dashed var(--line);
  padding-top: 12px;
}

.appearance-custom-theme-edit summary {
  cursor: pointer;
  color: var(--secondary);
  font-weight: 700;
  list-style: none;
}

.appearance-custom-theme-edit summary::-webkit-details-marker {
  display: none;
}

.appearance-custom-theme-edit-form {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.appearance-custom-theme-active-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--panel-surface);
  border: 1px solid var(--line);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}

.appearance-custom-theme-mini-preview {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 18px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--custom-surface) 86%, white 14%) 0%, white 100%);
  border: 1px solid var(--line);
  min-height: 118px;
}

.appearance-custom-theme-mini-preview__bar {
  display: block;
  height: 12px;
  border-radius: 999px;
  background: var(--custom-primary);
}

.appearance-custom-theme-mini-preview__body {
  display: grid;
  gap: 10px;
  padding: 10px;
  border-radius: 14px;
  background: white;
  border: 1px solid color-mix(in srgb, var(--custom-primary) 18%, var(--line));
}

.appearance-custom-theme-mini-preview__pill {
  display: inline-flex;
  width: 72px;
  height: 10px;
  border-radius: 999px;
  background: var(--custom-secondary);
}

.appearance-custom-theme-mini-preview__actions {
  display: flex;
  gap: 8px;
}

.appearance-custom-theme-mini-preview__actions span {
  display: block;
  height: 28px;
  border-radius: 10px;
}

.appearance-custom-theme-mini-preview__actions span:first-child {
  flex: 1;
  background: var(--custom-primary);
}

.appearance-custom-theme-mini-preview__actions span:last-child {
  width: 44%;
  background: color-mix(in srgb, var(--custom-secondary) 24%, white);
  border: 1px solid color-mix(in srgb, var(--custom-secondary) 38%, white);
}

.appearance-icon-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 8px 12px;
}

.appearance-icon-action.is-primary {
  border-color: var(--primary);
}

.appearance-icon-action.is-danger {
  border-color: rgba(214, 61, 79, 0.24);
  color: var(--danger);
}

.appearance-custom-theme-danger-btn {
  border-color: rgba(214, 61, 79, 0.24);
  color: var(--danger);
}

.appearance-custom-theme-danger-btn:hover {
  background: rgba(214, 61, 79, 0.08);
  border-color: rgba(214, 61, 79, 0.32);
  color: var(--danger);
}

.appearance-custom-theme-duplicate-btn {
  min-width: 96px;
}

.appearance-custom-theme-empty {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 24px 20px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: var(--panel-surface);
  text-align: center;
}

.appearance-custom-theme-empty i {
  font-size: 24px;
  color: var(--primary);
}

.appearance-custom-theme-empty h4,
.appearance-custom-theme-empty p {
  margin: 0;
}

.appearance-custom-theme-empty p {
  color: var(--muted);
  line-height: 1.5;
}

.appearance-custom-theme-banner {
  margin-bottom: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-surface);
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}

.appearance-custom-theme-name-fields {
  margin-bottom: 2px;
}

.appearance-custom-color-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.appearance-custom-color-field {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
}

.appearance-custom-color-field .helper-text {
  margin: 0;
}

.appearance-custom-color-input-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.appearance-custom-color-input-row input[type="color"] {
  width: 64px;
  min-width: 64px;
  height: 44px;
  padding: 4px;
  border-radius: 14px;
  cursor: pointer;
}

.appearance-custom-color-input-row input[type="text"] {
  min-width: 140px;
  text-transform: uppercase;
}

.appearance-custom-color-preview {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid color-mix(in srgb, var(--line) 88%, var(--primary) 12%);
  border-radius: 22px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
}

.appearance-custom-color-preview__header {
  display: grid;
  gap: 6px;
}

.appearance-custom-color-preview__header .section-title,
.appearance-custom-color-preview__header .section-subtitle {
  margin: 0;
}

.appearance-custom-theme-demo {
  min-height: 0;
}

.appearance-custom-theme-actions {
  display: grid;
  gap: 12px;
}

.appearance-custom-theme-actions > .helper-text {
  margin: 0;
}

.appearance-visual-branding-card .section-header {
  margin-bottom: 12px;
}

.appearance-branding-upload-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.appearance-branding-upload-item {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.appearance-branding-upload-item--header-bg {
  grid-column: 1 / -1;
  gap: 10px;
}

.appearance-branding-upload-item:hover {
  border-color: var(--color-button-outline-border);
  transform: translateY(-1px);
}

.appearance-branding-upload-item.is-drag-over {
  border-color: var(--primary);
  background: var(--color-button-outline-hover-bg);
  box-shadow: 0 0 0 1px var(--primary), var(--shadow-soft);
}

.appearance-branding-upload-item.has-pending-file {
  border-color: var(--primary);
}

.appearance-branding-upload-item.has-file-warning {
  border-color: var(--danger);
}

.appearance-branding-preview-box {
  display: grid;
  place-items: center;
  min-height: 118px;
  padding: 12px;
  border-radius: 16px;
  border: 1px dashed var(--line);
  background: var(--panel-surface);
}

.appearance-branding-preview-box--header-bg {
  min-height: 190px;
}

.appearance-branding-preview-img {
  max-width: 100%;
  max-height: 72px;
  object-fit: contain;
}

.appearance-branding-preview-img--favicon {
  max-height: 48px;
}

.appearance-branding-preview-img--header-bg {
  width: 100%;
  max-height: none;
  height: 168px;
  border-radius: 12px;
  object-fit: cover;
  object-position: center;
}

.appearance-branding-upload-item .form-group {
  display: grid;
  gap: 6px;
}

.appearance-branding-upload-item .helper-text {
  margin: 0;
  line-height: 1.4;
}

.appearance-branding-field-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 2px;
}

.appearance-branding-field-head--card {
  margin-bottom: 0;
}

.appearance-branding-field-head label {
  margin: 0;
}

.appearance-branding-remove-btn,
.appearance-branding-remove-btn.btn,
.appearance-branding-remove-btn.btn.btn-secondary {
  min-height: 34px;
  padding: 6px 10px;
  font-size: 12px;
  gap: 6px;
  background: var(--card);
  color: var(--color-button-tertiary-text, var(--primary));
  border: 1px solid var(--color-button-tertiary-border, var(--line));
  box-shadow: none;
}

.appearance-branding-remove-btn i,
.appearance-branding-remove-btn .fa,
.appearance-branding-remove-btn .fa-solid {
  color: currentColor;
}

.appearance-branding-remove-btn:hover,
.appearance-branding-remove-btn.btn:hover,
.appearance-branding-remove-btn.btn.btn-secondary:hover {
  background: var(--color-button-tertiary-hover, var(--panel-surface));
  color: var(--color-button-tertiary-text, var(--primary));
  border-color: var(--color-button-tertiary-text, var(--primary));
  transform: none;
}

.appearance-branding-placeholder {
  display: grid;
  gap: 8px;
  justify-items: center;
  color: var(--muted);
  text-align: center;
}

.appearance-branding-placeholder i {
  font-size: 22px;
  color: var(--primary);
}

.appearance-branding-drop-hint {
  font-size: 12px;
  line-height: 1.35;
}

.appearance-branding-file-name {
  min-height: 18px;
}

.appearance-branding-form-group--header-bg {
  width: 100%;
  max-width: none;
  justify-self: stretch;
}

.appearance-branding-form-group--header-bg [data-branding-file-input],
.appearance-branding-form-group--header-bg input[type="file"] {
  width: 100%;
  max-width: 100%;
  display: block;
  justify-self: stretch;
}

.appearance-branding-upload-item.has-pending-file .appearance-branding-file-name {
  color: var(--primary);
  font-weight: 700;
}

.appearance-branding-upload-item.has-file-warning .appearance-branding-file-name {
  color: var(--danger);
  font-weight: 700;
}

.appearance-branding-upload-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 2px;
  margin-bottom: 24px;
}

.appearance-visual-branding-modal {
  width: min(1280px, calc(100vw - 48px));
  max-width: none;
}

.appearance-visual-branding-modal .appearance-modal-body {
  padding: 20px 22px 22px;
}

.appearance-preset-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
  margin-top: 0;
  align-items: stretch;
}

.appearance-preset-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  min-height: 100%;
}

.appearance-preset-card.is-active {
  background: var(--panel-surface);
}

.appearance-preset-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.appearance-preset-card-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.appearance-preset-card-head h4 {
  margin: 0;
}

.appearance-preset-tag {
  min-width: 104px;
  flex-shrink: 0;
  text-align: center;
}

.appearance-preset-description {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.appearance-swatch-row {
  margin-top: auto;
  align-items: flex-end;
}

.appearance-coming-soon-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-top: 0;
}

.appearance-coming-soon-item {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  padding: 14px 16px;
}

.appearance-coming-soon-item span:last-child {
  grid-column: 2;
  justify-self: start;
  margin-top: 4px;
  padding: 5px 9px;
  border-radius: 999px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
}

@media (max-width: 1200px) {
  .appearance-selector-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .appearance-notice-band {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .appearance-notice-band__accent {
    display: none;
  }

.appearance-selector-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-preview-header,
  .appearance-demo-hero-card {
    flex-direction: column;
    align-items: flex-start;
  }

  .appearance-demo-support-grid {
    grid-template-columns: 1fr;
  }

  .appearance-branding-grid {
    grid-template-columns: 1fr;
  }

  .appearance-custom-theme-status {
    align-items: flex-start;
    flex-direction: column;
  }

  .appearance-custom-color-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-custom-theme-list {
    grid-template-columns: 1fr;
  }

  .appearance-custom-theme-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .appearance-custom-theme-helper {
    max-width: none;
  }

  .appearance-custom-theme-actions-menu,
  .appearance-custom-theme-secondary-actions {
    justify-items: stretch;
    justify-content: stretch;
  }

  .appearance-branding-upload-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-branding-upload-item--header-bg {
    grid-column: 1 / -1;
  }

  .appearance-preview-control-bar {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .appearance-preview-control-right {
    justify-items: stretch;
    justify-self: stretch;
    min-width: 0;
  }

  .appearance-preview-buttons {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    flex-wrap: nowrap;
  }

  .appearance-preview-buttons .appearance-inline-form,
  .appearance-preview-buttons form,
  .appearance-preview-buttons .appearance-actions-row,
  .appearance-preview-buttons .btn {
    width: 100%;
  }

  .appearance-actions-helper {
    text-align: left;
    max-width: none;
  }
}

@media (max-width: 767px) {
  .appearance-page-shell {
    gap: 18px;
  }

  .appearance-notice-band,
  .appearance-selector-card,
  .appearance-preview-workspace,
  .appearance-library-card,
  .appearance-coming-soon-card,
  .appearance-live-preview {
    padding: 16px;
  }

  .appearance-selector-grid {
    grid-template-columns: 1fr;
  }

  .appearance-custom-color-grid {
    grid-template-columns: 1fr;
  }

  .appearance-custom-theme-head,
  .appearance-preset-card-head,
  .appearance-custom-theme-swatches {
    flex-direction: column;
    align-items: flex-start;
  }

  .appearance-custom-theme-layout {
    grid-template-columns: 1fr;
  }

  .appearance-selector-option {
    padding: 13px 14px;
  }

  .appearance-coming-soon-grid {
    grid-template-columns: 1fr;
  }

  .appearance-preview-control-bar,
  .appearance-inline-form,
  .appearance-actions-row {
    width: 100%;
  }

  .appearance-actions-row .btn {
    width: 100%;
    justify-content: center;
  }

  .appearance-custom-theme-actions-menu,
  .appearance-custom-theme-secondary-actions {
    justify-items: stretch;
    justify-content: flex-start;
  }

  .appearance-branding-actions,
  .appearance-branding-actions .btn,
  .appearance-custom-theme-actions .btn,
  .appearance-custom-theme-actions-menu .btn,
  .appearance-custom-theme-secondary-actions .btn,
  .appearance-branding-upload-actions,
  .appearance-branding-upload-actions .btn {
    width: 100%;
  }

  .appearance-branding-upload-grid {
    grid-template-columns: 1fr;
  }

  .appearance-branding-upload-item--header-bg {
    grid-column: auto;
  }
}

/* Fase 5A.3 - Hub compacto */
.appearance-status-grid,
.appearance-hub-grid {
  display: grid;
  gap: 14px;
}

.appearance-status-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.appearance-hub-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.appearance-status-card,
.appearance-hub-card {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.appearance-status-card i,
.appearance-hub-card i {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--primary);
  box-shadow: var(--shadow-soft);
}

.appearance-status-card strong,
.appearance-hub-card .section-title {
  margin: 0;
  color: var(--color-title);
}

.appearance-status-card p,
.appearance-hub-card .section-subtitle {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.appearance-hub-card {
  align-content: start;
}

.appearance-hub-card .btn {
  justify-self: start;
  margin-top: 2px;
}

.appearance-compact-preview-card {
  padding: 20px;
}

.appearance-compact-preview {
  margin-top: 8px;
}

.appearance-modal-open {
  overflow: hidden;
}

.appearance-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 2500;
}

.appearance-modal.is-open {
  display: block;
}

.appearance-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 27, 40, 0.5);
}

.appearance-modal-panel {
  position: relative;
  width: min(920px, calc(100vw - 32px));
  max-height: min(92vh, 980px);
  margin: 5vh auto;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border-radius: 24px;
  background: var(--card);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.appearance-modal-panel--wide {
  width: min(1280px, calc(100vw - 32px));
}

.appearance-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-surface);
}

.appearance-modal-body {
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px;
}

.appearance-modal-body .appearance-preview-workspace,
.appearance-modal-body .appearance-theme-hub-card,
.appearance-modal-body .appearance-custom-themes-card,
.appearance-modal-body .appearance-custom-theme-card,
.appearance-modal-body .appearance-branding-card,
.appearance-modal-body .appearance-visual-branding-card,
.appearance-modal-body .appearance-coming-soon-card {
  margin: 0;
  padding: 0;
  box-shadow: none;
  border: none;
  background: transparent;
}

.appearance-page-shell > #appearanceThemeHub,
.appearance-page-shell > .appearance-custom-themes-card {
  display: none;
}

.appearance-theme-modal-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  margin-bottom: 18px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
}

.appearance-theme-modal-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 9px 14px;
  flex: 0 0 auto;
  border: 1px solid var(--color-button-outline-border);
  border-radius: 999px;
  background: var(--color-button-outline-bg);
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.appearance-theme-modal-tab:hover {
  background: var(--color-button-outline-hover-bg);
}

.appearance-theme-modal-tab.is-active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
  box-shadow: var(--shadow-soft);
}

.appearance-theme-modal-panel {
  display: none;
}

.appearance-theme-modal-panel.is-active {
  display: block;
  min-width: 0;
}

.appearance-theme-hub-card {
  padding: 20px;
}

.appearance-theme-hub-card--modal,
.appearance-custom-themes-card--modal {
  padding: 0;
}

.appearance-theme-hub-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.85fr) minmax(520px, 1.15fr);
  gap: 24px;
  align-items: stretch;
}

.appearance-theme-list {
  display: grid;
  gap: 12px;
}

.appearance-theme-option {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  text-align: left;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.appearance-theme-option:hover {
  transform: translateY(-1px);
  border-color: var(--color-button-outline-border);
}

.appearance-theme-option.is-selected,
.appearance-theme-option.is-active {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary), var(--shadow);
  background: var(--panel-surface);
}

.appearance-theme-option-main {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.appearance-theme-option-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.appearance-theme-option-check {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-soft);
  color: transparent;
  border: 1px solid var(--line);
  flex-shrink: 0;
}

.appearance-theme-option-check i {
  color: inherit;
  font-size: 13px;
  line-height: 1;
}

.appearance-theme-option.is-selected .appearance-theme-option-check,
.appearance-theme-option.is-active .appearance-theme-option-check {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2) inset;
}

.appearance-theme-preview-panel {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-content: flex-start;
  gap: 0;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--line) 88%, var(--primary) 12%);
  border-radius: 24px;
  background: var(--card);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.appearance-theme-hub-layout > .appearance-theme-preview-panel {
  border-left-color: transparent;
}

.appearance-theme-preview-panel .appearance-preview-header {
  margin-bottom: 0;
  gap: 12px;
  padding: 22px 22px 10px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel-surface) 90%, white 10%) 0%, var(--card) 100%);
}

.appearance-theme-preview-panel .appearance-live-preview-copy {
  gap: 4px;
}

.appearance-theme-preview-panel .appearance-kicker {
  margin-bottom: 0;
  line-height: 1.15;
}

.appearance-theme-preview-panel .appearance-live-preview-title {
  line-height: 1.12;
  margin: 0;
}

.appearance-theme-preview-panel .appearance-live-preview-subtitle {
  max-width: none;
  line-height: 1.4;
  margin: 0;
}

.appearance-theme-preview-status {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 8px;
  margin: 0;
  padding: 0 22px 18px;
  background: var(--card);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 84%, white 16%);
}

.appearance-theme-preview-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  width: 100%;
}

.appearance-theme-preview-helper {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.appearance-theme-preview-panel .appearance-preview-control-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.appearance-theme-preview-panel .appearance-preview-control-right {
  margin-left: auto;
}

.appearance-theme-preview-panel .appearance-live-preview {
  margin-top: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  background: var(--app-background);
}

.appearance-theme-preview-panel .appearance-demo-topbar {
  margin-bottom: 16px;
  padding: 18px;
}

.appearance-color-editor-preview .appearance-demo-chrome {
  padding: 12px;
  border-radius: 22px;
  background: color-mix(in srgb, var(--panel-surface) 88%, white 12%);
  border: 1px solid color-mix(in srgb, var(--line) 82%, white 18%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.appearance-theme-preview-panel .appearance-demo-chrome {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.appearance-color-editor-preview .appearance-demo-stage {
  padding: 10px 0 0;
  border-radius: 20px;
  background: transparent;
}

.appearance-theme-preview-panel .appearance-demo-stage {
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.appearance-color-editor-preview .appearance-demo-hero-card,
.appearance-color-editor-preview .appearance-demo-card {
  background: color-mix(in srgb, var(--card) 95%, white 5%);
  border-color: color-mix(in srgb, var(--line) 80%, white 20%);
}

.appearance-color-editor-preview .appearance-demo-card--soft {
  background: var(--card-surface);
  border-color: color-mix(in srgb, var(--line) 82%, white 18%);
}

.appearance-color-editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.82fr);
  gap: 24px;
  align-items: start;
}

.appearance-color-editor-config,
.appearance-color-editor-preview {
  min-width: 0;
}

.appearance-color-editor-modal {
  width: min(98vw, 1560px);
  max-width: 1560px;
}

.appearance-color-editor-modal .appearance-modal-body {
  padding: 26px 28px 30px;
}

.appearance-color-editor-preview {
  position: sticky;
  top: 16px;
  align-self: start;
  justify-self: stretch;
  max-height: calc(100dvh - 150px);
  overflow: hidden;
}

.appearance-color-editor-preview .appearance-custom-color-preview {
  margin: 0;
  align-self: start;
  padding: 20px;
  max-height: calc(100dvh - 170px);
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 8px;
}

.appearance-color-editor-preview .appearance-live-preview {
  padding: 16px;
  background: var(--app-background);
  border: 1px solid color-mix(in srgb, var(--secondary) 22%, var(--line) 78%);
  border-radius: 24px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.58),
    0 10px 24px rgba(74, 88, 153, 0.06);
}

.appearance-color-editor-preview .appearance-demo-chrome {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.appearance-color-editor-preview .appearance-demo-stage {
  padding: 10px 0 0;
}

.appearance-color-editor-preview .appearance-demo-topbar,
.appearance-color-editor-preview .appearance-demo-hero-card,
.appearance-color-editor-preview .appearance-demo-card {
  padding: 14px;
}

.appearance-color-editor-preview .appearance-system-preview__content,
.appearance-color-editor-preview .appearance-system-preview__grid,
.appearance-color-editor-preview .appearance-demo-stage,
.appearance-color-editor-preview .appearance-demo-support-grid {
  gap: 12px;
}

.appearance-color-editor-preview .appearance-system-preview__content,
.appearance-color-editor-preview .appearance-system-preview__grid,
.appearance-color-editor-preview .appearance-system-preview__table-card {
  --card-padding: clamp(16px, var(--card-padding, 22px), 24px);
}

.appearance-color-editor-preview .appearance-demo-topbar-copy,
.appearance-color-editor-preview .appearance-demo-hero-card__copy,
.appearance-color-editor-preview .appearance-system-preview__table-header > div {
  gap: 6px;
}

.appearance-color-editor-preview .appearance-system-preview__table th,
.appearance-color-editor-preview .appearance-system-preview__table td {
  padding: 9px 10px;
}

.appearance-color-editor-preview .appearance-system-preview__table {
  min-width: 0;
}

.appearance-color-editor-config .appearance-branding-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.appearance-color-editor-config .appearance-custom-color-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.appearance-color-editor-config .appearance-custom-color-field {
  padding: 18px;
}

.appearance-color-editor-config .appearance-custom-color-field--gradient {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-color-editor-config .appearance-custom-color-field--card-surface {
  padding: 18px;
  grid-column: 1 / -1;
  width: 100%;
}

.appearance-color-editor-config .appearance-custom-color-field--badge {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-color-editor-config .appearance-custom-color-field--tertiary-button {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split,
.appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split--tertiary-button {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.appearance-color-editor-config .appearance-custom-color-field--button-builder {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-color-editor-config .appearance-custom-color-field--typography-density {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-color-editor-config .appearance-custom-color-field--segmented-controls {
  padding: 18px;
  grid-column: 1 / -1;
}

.appearance-button-builder-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.appearance-button-builder-grid--visual-density {
  margin-top: 12px;
}

.appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split,
.appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split--segmented-controls {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.appearance-button-control-group {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel-surface);
}

.appearance-button-control-head {
  display: grid;
  gap: 4px;
}

.appearance-button-control-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

.appearance-button-control-help {
  font-size: 12px;
  line-height: 1.45;
  color: var(--muted);
}

.appearance-button-segmented-control {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.appearance-button-segment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.appearance-button-segment:hover {
  background: var(--color-button-outline-hover-bg);
}

.appearance-button-segment.is-active {
  background: var(--panel-surface);
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: var(--shadow-soft);
}

.appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split,
.appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split--card-surface {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.appearance-custom-color-field-split {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 10px;
}

.appearance-custom-color-stop {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.appearance-custom-color-stop-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.appearance-color-editor-config .appearance-custom-color-field .helper-text {
  font-size: 12px;
  line-height: 1.4;
}

.appearance-custom-theme-actions {
  margin-top: 24px;
  padding-bottom: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.appearance-custom-theme-actions > .helper-text {
  max-width: 520px;
}

.appearance-custom-theme-actions .appearance-preview-buttons {
  gap: 14px;
}

.appearance-color-editor-preview .appearance-demo-support-grid {
  gap: 14px;
}

.appearance-modal-close {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--color-button-outline-bg);
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 1440px) {
  .appearance-color-editor-modal {
    width: min(98vw, 1440px);
    max-width: 1440px;
  }

  .appearance-color-editor-layout {
    grid-template-columns: minmax(0, 1fr) minmax(380px, 0.78fr);
    gap: 20px;
  }
}

@media (max-width: 1320px) {
  .appearance-modal-panel--wide,
  .appearance-color-editor-modal {
    width: min(97vw, 1240px);
    max-width: 1240px;
  }

  .appearance-visual-branding-modal {
    width: min(1280px, calc(100vw - 40px));
    max-width: none;
  }

  .appearance-color-editor-modal .appearance-modal-body {
    padding: 22px 22px 26px;
  }

  .appearance-color-editor-layout {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.74fr);
    gap: 18px;
  }
}

@media (max-width: 1180px) and (min-width: 768px) {
  .appearance-modal-panel--wide,
  .appearance-color-editor-modal {
    width: calc(100vw - 32px);
    max-width: none;
    max-height: calc(100dvh - 28px);
    margin: 14px auto;
  }

  .appearance-modal-header {
    padding: 16px 18px;
    gap: 14px;
  }

  .appearance-modal-body,
  .appearance-color-editor-modal .appearance-modal-body {
    padding: 18px 18px 22px;
  }

  .appearance-theme-modal-tabs {
    gap: 8px;
    margin-bottom: 16px;
  }

  .appearance-theme-modal-tab {
    min-height: 42px;
    padding: 10px 14px;
  }

  .appearance-custom-theme-actions {
    padding-bottom: 18px;
  }

  .appearance-visual-branding-modal {
    width: calc(100vw - 32px);
  }

  .appearance-visual-branding-modal .appearance-modal-body {
    padding: 18px 18px 22px;
  }
}

@media (max-width: 1099px) {
  .appearance-status-grid,
  .appearance-hub-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-theme-hub-layout {
    grid-template-columns: 1fr;
  }

  .appearance-custom-theme-list-compact .appearance-custom-theme-layout {
    grid-template-columns: 1fr;
  }

  .appearance-color-editor-layout {
    grid-template-columns: 1fr;
  }

  .appearance-color-editor-preview {
    position: static;
    top: auto;
    max-height: none;
    overflow: visible;
  }

  .appearance-color-editor-preview .appearance-custom-color-preview {
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }

  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split--segmented-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-color-editor-config .appearance-custom-color-grid {
    grid-template-columns: 1fr;
  }

  .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split--card-surface,
  .appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split--tertiary-button {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-button-builder-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1023px) and (min-width: 768px) {
  .appearance-custom-color-input-row {
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 8px;
  }

  .appearance-custom-color-input-row input[type="color"] {
    width: 56px;
    min-width: 56px;
    height: 42px;
  }

  .appearance-button-builder-grid,
  .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split--card-surface,
  .appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--tertiary-button .appearance-custom-color-field-split--tertiary-button,
  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split--segmented-controls {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .appearance-status-grid,
  .appearance-hub-grid {
    grid-template-columns: 1fr;
  }

  .appearance-modal-panel,
  .appearance-modal-panel--wide {
    width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
    margin: 8px auto;
    border-radius: 18px;
  }

  .appearance-modal-header,
  .appearance-modal-body,
  .appearance-compact-preview-card {
    padding: 16px;
  }

  .appearance-visual-branding-modal .appearance-modal-body {
    padding: 16px;
  }

  .appearance-modal-header {
    align-items: flex-start;
    gap: 12px;
  }

  .appearance-color-editor-modal .appearance-modal-body {
    padding: 16px;
  }

  .appearance-theme-modal-tabs {
    gap: 8px;
    flex-wrap: nowrap;
    padding-bottom: 2px;
  }

  .appearance-theme-modal-tab {
    width: auto;
    min-width: max-content;
  }

  .appearance-color-editor-config .appearance-branding-grid,
  .appearance-color-editor-config .appearance-custom-color-grid {
    grid-template-columns: 1fr;
  }

  .appearance-custom-color-field-split {
    grid-template-columns: 1fr;
  }

  .appearance-custom-color-input-row {
    grid-template-columns: 1fr;
  }

  .appearance-custom-color-input-row input[type="color"] {
    width: 100%;
    min-width: 0;
  }

  .appearance-button-builder-grid {
    grid-template-columns: 1fr;
  }

  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--card-surface .appearance-custom-color-field-split--card-surface,
  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split,
  .appearance-color-editor-config .appearance-custom-color-field--segmented-controls .appearance-custom-color-field-split--segmented-controls {
    grid-template-columns: 1fr;
  }

  .appearance-theme-option-main,
  .appearance-theme-preview-actions {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: flex-start;
  }

  .appearance-theme-preview-actions .btn,
  .appearance-theme-preview-actions form {
    width: 100%;
  }

  .appearance-custom-theme-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding-bottom: 16px;
  }
}

.appearance-hub-card .btn {
  width: 100%;
  justify-self: stretch;
}

.appearance-white-label-flow {
  display: grid;
  gap: 26px;
  margin-bottom: 28px;
}

.appearance-white-label-flow__intro {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 18px 22px;
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(247, 250, 255, 0.94) 100%);
  border: 1px solid rgba(205, 218, 244, 0.78);
  box-shadow: 0 12px 26px rgba(70, 86, 130, 0.06);
}

.appearance-white-label-flow__intro-copy {
  display: grid;
  gap: 8px;
}

.appearance-white-label-flow__intro-copy .section-title,
.appearance-white-label-flow__intro-copy .section-subtitle {
  margin: 0;
}

.appearance-white-label-flow__intro-copy .section-title {
  font-size: clamp(1.25rem, 2vw, 1.7rem);
  line-height: 1.18;
}

.appearance-white-label-flow__intro-copy .section-subtitle {
  max-width: 780px;
}

.appearance-white-label-flow__intro-stats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.appearance-white-label-flow__intro-stat {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 80px;
  padding: 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(204, 216, 244, 0.84);
  background: rgba(255, 255, 255, 0.94);
}

.appearance-white-label-flow__intro-stat > i {
  position: relative;
  width: 34px;
  height: 34px;
  min-width: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  flex: 0 0 auto;
  box-sizing: border-box;
  color: var(--color-button-primary, var(--color-primary));
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  font-size: 0.84rem;
}

.appearance-white-label-flow__intro-copyline,
.appearance-white-label-flow__intro-copyline strong,
.appearance-white-label-flow__intro-copyline span {
  display: block;
}

.appearance-white-label-flow__intro-copyline strong {
  color: var(--color-title, var(--primary));
  font-size: 0.94rem;
  line-height: 1.2;
}

.appearance-white-label-flow__intro-copyline span {
  color: var(--color-text-secondary, var(--muted));
  font-size: 0.82rem;
  line-height: 1.45;
}

.appearance-onboarding-card {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 24px;
  padding: 28px;
  border-radius: 30px;
  background:
    radial-gradient(circle at top right, rgba(214, 227, 255, 0.68), transparent 28%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 255, 0.98) 100%);
  border: 1px solid rgba(201, 214, 242, 0.78);
  box-shadow: 0 18px 44px rgba(60, 76, 122, 0.09);
  overflow: hidden;
}

.appearance-onboarding-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, var(--appearance-onboarding-accent, rgba(90, 127, 241, 0.42)) 0%, transparent 85%);
  opacity: 0.95;
}

.appearance-onboarding-card > * {
  position: relative;
  z-index: 1;
}

.white-label-checklist {
  --appearance-onboarding-accent: rgba(86, 129, 255, 0.5);
}

.brand-config-guide {
  --appearance-onboarding-accent: rgba(89, 184, 214, 0.5);
}

.visual-config-guide {
  --appearance-onboarding-accent: rgba(168, 112, 255, 0.46);
}

.operational-qa-guide {
  --appearance-onboarding-accent: rgba(74, 208, 176, 0.48);
}

.delivery-final-guide {
  --appearance-onboarding-accent: rgba(255, 174, 92, 0.48);
}

.demo-commercial-guide {
  --appearance-onboarding-accent: rgba(255, 118, 177, 0.46);
}

.sales-arguments-guide {
  --appearance-onboarding-accent: rgba(113, 144, 255, 0.46);
}

.demo-ready-guide {
  --appearance-onboarding-accent: rgba(83, 191, 152, 0.46);
}

.appearance-onboarding-hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: start;
}

.appearance-onboarding-hero__copy {
  display: grid;
  gap: 6px;
}

.appearance-onboarding-hero__copy .section-title,
.appearance-onboarding-summary h4 {
  margin: 0;
}

.appearance-onboarding-hero__copy .section-subtitle,
.appearance-onboarding-summary p,
.appearance-onboarding-hero__note p {
  margin: 0;
}

.appearance-onboarding-hero__copy .section-subtitle {
  max-width: 760px;
}

.appearance-onboarding-hero__note {
  display: grid;
  gap: 12px;
  width: 100%;
  padding: 16px 18px;
  border-radius: 24px;
  border: 1px solid rgba(197, 212, 244, 0.85);
  background: linear-gradient(180deg, rgba(245, 248, 255, 0.98) 0%, rgba(255, 255, 255, 0.95) 100%);
  box-shadow: 0 14px 28px rgba(66, 83, 124, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.appearance-onboarding-note__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 6px 11px;
  border-radius: 999px;
  background: rgba(231, 239, 255, 0.9);
  border: 1px solid rgba(184, 203, 246, 0.92);
  color: var(--color-button-primary, var(--color-primary));
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.white-label-checklist__summary-head {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 12px;
}

.white-label-checklist__summary-head p {
  color: var(--color-text-secondary, var(--muted));
  font-size: 0.88rem;
  text-align: left;
}

.white-label-checklist__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.white-label-checklist__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-start;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
  min-height: 54px;
}

.white-label-checklist__summary-pills li i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  color: var(--color-button-primary, var(--color-primary));
  flex: 0 0 auto;
}

.appearance-onboarding-hero__note p,
.appearance-onboarding-summary p,
.appearance-onboarding-block__head p,
.appearance-onboarding-summary__stat span {
  color: var(--color-text-secondary, var(--muted));
  line-height: 1.55;
}

.appearance-onboarding-hero__note p,
.appearance-onboarding-summary p,
.appearance-onboarding-block__head p {
  font-size: 0.93rem;
}

.appearance-onboarding-layout {
  display: grid;
  gap: 20px;
}

.appearance-onboarding-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.appearance-onboarding-block {
  position: relative;
  display: grid;
  gap: 18px;
  padding: 20px 20px 22px;
  border-radius: 24px;
  border: 1px solid rgba(197, 210, 241, 0.78);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(246, 249, 255, 0.98) 100%);
  box-shadow: 0 14px 30px rgba(62, 79, 126, 0.08);
  overflow: hidden;
}

.appearance-onboarding-block::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  opacity: 0.95;
}

.white-label-checklist__card--identity::after {
  background: linear-gradient(90deg, #71a2ff 0%, #4d7fff 100%);
}

.white-label-checklist__card--visual::after {
  background: linear-gradient(90deg, #d191ff 0%, #a667f5 100%);
}

.white-label-checklist__card--operational::after {
  background: linear-gradient(90deg, #59d7e0 0%, #19b8c7 100%);
}

.white-label-checklist__card--delivery::after {
  background: linear-gradient(90deg, #ff9ed6 0%, #ff5db1 100%);
}

.appearance-onboarding-block__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.appearance-onboarding-step {
  color: rgba(104, 120, 170, 0.72);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.appearance-onboarding-icon {
  width: 48px;
  height: 48px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(234, 241, 255, 0.98) 0%, rgba(245, 248, 255, 0.98) 100%);
  border: 1px solid rgba(188, 204, 241, 0.88);
  color: var(--color-button-primary, var(--color-primary));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.white-label-checklist__card--identity .appearance-onboarding-icon,
.white-label-checklist__card--identity .appearance-onboarding-check,
.white-label-checklist__card--identity .white-label-checklist__step {
  color: #2f6ef1;
}

.white-label-checklist__card--identity .appearance-onboarding-icon,
.white-label-checklist__card--identity .appearance-onboarding-check,
.white-label-checklist__card--identity .white-label-checklist__step {
  border-color: rgba(136, 174, 255, 0.85);
  background: rgba(236, 243, 255, 0.92);
}

.white-label-checklist__card--visual .appearance-onboarding-icon,
.white-label-checklist__card--visual .appearance-onboarding-check,
.white-label-checklist__card--visual .white-label-checklist__step {
  color: #8a4de8;
  border-color: rgba(208, 171, 255, 0.82);
  background: rgba(248, 240, 255, 0.94);
}

.white-label-checklist__card--operational .appearance-onboarding-icon,
.white-label-checklist__card--operational .appearance-onboarding-check,
.white-label-checklist__card--operational .white-label-checklist__step {
  color: #1298a6;
  border-color: rgba(148, 229, 235, 0.84);
  background: rgba(235, 252, 253, 0.94);
}

.white-label-checklist__card--delivery .appearance-onboarding-icon,
.white-label-checklist__card--delivery .appearance-onboarding-check,
.white-label-checklist__card--delivery .white-label-checklist__step {
  color: #ec4d9d;
  border-color: rgba(255, 181, 222, 0.85);
  background: rgba(255, 241, 248, 0.95);
}

.appearance-onboarding-block__head {
  display: grid;
  gap: 6px;
}

.appearance-onboarding-block__head h4 {
  margin: 0;
  color: var(--color-title, var(--primary));
  font-size: 1.02rem;
  line-height: 1.25;
}

.appearance-onboarding-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.appearance-onboarding-list li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(224, 230, 245, 0.78);
  color: var(--color-text, var(--text));
  font-size: 0.92rem;
  line-height: 1.45;
}

.appearance-onboarding-list li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.appearance-onboarding-check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(230, 238, 255, 0.95);
  border: 1px solid rgba(184, 201, 239, 0.88);
  color: var(--color-button-primary, var(--color-primary));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.appearance-onboarding-summary {
  display: grid;
  gap: 20px;
  padding: 22px 24px;
  border-radius: 24px;
  border: 1px solid rgba(196, 211, 244, 0.82);
  background: linear-gradient(180deg, rgba(244, 248, 255, 0.96) 0%, rgba(255, 255, 255, 0.96) 100%);
  box-shadow: 0 14px 30px rgba(62, 79, 126, 0.08);
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 2fr);
  align-items: center;
}

.appearance-onboarding-summary h4 {
  color: var(--color-title, var(--primary));
  font-size: 1.55rem;
  line-height: 1.3;
}

.white-label-checklist__footer-copy {
  display: flex;
  align-items: center;
  gap: 16px;
}

.white-label-checklist__footer-icon {
  width: 66px;
  height: 66px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: #2f6ef1;
  background: radial-gradient(circle at top left, rgba(234, 242, 255, 0.98), rgba(244, 248, 255, 0.98));
  border: 1px solid rgba(195, 210, 244, 0.82);
  font-size: 1.5rem;
}

.appearance-onboarding-summary__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.appearance-onboarding-summary__stat {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(205, 217, 244, 0.82);
  display: grid;
  gap: 6px;
  justify-items: start;
}

.appearance-onboarding-summary__stat strong {
  color: var(--color-button-primary, var(--color-primary));
  font-size: 1.2rem;
  line-height: 1.1;
}

.white-label-checklist__step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(236, 241, 255, 0.92);
  border: 1px solid rgba(192, 206, 242, 0.92);
}

.white-label-checklist__stat-icon {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 242, 255, 0.96);
  border: 1px solid rgba(192, 206, 242, 0.84);
  color: var(--color-button-primary, var(--color-primary));
  font-size: 1rem;
}

.white-label-checklist__item span:last-child {
  min-width: 0;
}

.appearance-onboarding-summary__stat span {
  font-size: 0.82rem;
}

.appearance-onboarding-summary__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.appearance-onboarding-summary__list li {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: var(--color-text, var(--text));
  font-size: 0.9rem;
  line-height: 1.5;
}

.appearance-onboarding-summary__list i {
  color: var(--color-button-primary, var(--color-primary));
  margin-top: 2px;
}

.brand-config-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.brand-config-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
  min-height: 54px;
}

.brand-config-guide__summary-pills li i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  color: var(--color-button-primary, var(--color-primary));
  flex: 0 0 auto;
}

.brand-config-guide__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.brand-config-guide__card--identity::after {
  background: linear-gradient(90deg, #6f99ff 0%, #4477f0 100%);
}

.brand-config-guide__card--branding::after {
  background: linear-gradient(90deg, #70d2f2 0%, #2bb7d4 100%);
}

.brand-config-guide__card--appearance::after {
  background: linear-gradient(90deg, #9d8dff 0%, #715cf0 100%);
}

.brand-config-guide__card--content::after {
  background: linear-gradient(90deg, #ff9bbb 0%, #f56d97 100%);
}

.brand-config-guide__card--identity .appearance-onboarding-icon,
.brand-config-guide__card--identity .brand-config-guide__check,
.brand-config-guide__card--identity .brand-config-guide__step {
  color: #356ff0;
  border-color: rgba(140, 176, 255, 0.84);
  background: rgba(237, 244, 255, 0.92);
}

.brand-config-guide__card--branding .appearance-onboarding-icon,
.brand-config-guide__card--branding .brand-config-guide__check,
.brand-config-guide__card--branding .brand-config-guide__step {
  color: #1b9aba;
  border-color: rgba(157, 229, 244, 0.84);
  background: rgba(239, 251, 255, 0.94);
}

.brand-config-guide__card--appearance .appearance-onboarding-icon,
.brand-config-guide__card--appearance .brand-config-guide__check,
.brand-config-guide__card--appearance .brand-config-guide__step {
  color: #6b58e8;
  border-color: rgba(192, 182, 255, 0.84);
  background: rgba(243, 240, 255, 0.94);
}

.brand-config-guide__card--content .appearance-onboarding-icon,
.brand-config-guide__card--content .brand-config-guide__check,
.brand-config-guide__card--content .brand-config-guide__step {
  color: #e1598c;
  border-color: rgba(255, 188, 212, 0.84);
  background: rgba(255, 242, 248, 0.95);
}

.brand-config-guide__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.brand-config-guide__item span:last-child {
  min-width: 0;
}

@media (max-width: 1120px) {
  .appearance-white-label-flow__intro {
    grid-template-columns: 1fr;
  }

  .appearance-white-label-flow__intro-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .appearance-onboarding-layout,
  .appearance-onboarding-summary {
    grid-template-columns: 1fr;
  }

  .brand-config-guide__summary-pills,
  .white-label-checklist__summary-pills {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1480px) {
  .appearance-onboarding-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .appearance-white-label-flow {
    gap: 22px;
  }

  .appearance-white-label-flow__intro-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .appearance-onboarding-summary__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .white-label-checklist__summary-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .white-label-checklist__summary-head p {
    text-align: left;
  }

  .appearance-onboarding-grid {
    grid-template-columns: 1fr;
  }

  .brand-config-guide__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .appearance-white-label-flow__intro {
    padding: 18px;
  }

  .appearance-white-label-flow__intro-stats {
    grid-template-columns: 1fr;
  }

  .appearance-onboarding-card {
    padding: 22px 18px;
  }

  .appearance-onboarding-block,
  .appearance-onboarding-summary,
  .appearance-onboarding-hero__note {
    padding: 18px;
  }

  .brand-config-guide__summary-pills,
  .white-label-checklist__summary-pills,
  .appearance-onboarding-summary__stats {
    grid-template-columns: 1fr;
  }

  .white-label-checklist__footer-copy {
    align-items: flex-start;
    flex-direction: column;
  }

  .brand-config-guide__grid {
    grid-template-columns: 1fr;
  }
}

.visual-config-guide {
  gap: 22px;
}

.visual-config-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.visual-config-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.visual-config-guide__summary-pills i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  color: var(--color-button-primary, var(--color-primary));
  flex: 0 0 auto;
}

.visual-config-guide__body,
.visual-config-guide__stack {
  display: grid;
  gap: 20px;
}

.visual-config-guide__panel {
  display: grid;
  gap: 18px;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(197, 210, 241, 0.78);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(246, 249, 255, 0.98) 100%);
  box-shadow: 0 14px 30px rgba(62, 79, 126, 0.08);
}

.visual-config-guide__panel-head {
  display: grid;
  gap: 6px;
}

.visual-config-guide__panel-head h4 {
  margin: 0;
  color: var(--color-title, var(--primary));
  font-size: 1.08rem;
  line-height: 1.3;
}

.visual-config-guide__panel-head p {
  margin: 0;
  color: var(--color-text-secondary, var(--muted));
  font-size: 0.93rem;
  line-height: 1.55;
}

.visual-config-guide__preset-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.visual-config-guide__preset-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 22px;
  border: 1px solid rgba(203, 216, 245, 0.82);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(248, 250, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.74);
}

.visual-config-guide__preset-card--recommended {
  border-color: rgba(153, 183, 255, 0.92);
  background: linear-gradient(180deg, rgba(242, 247, 255, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
}

.visual-config-guide__preset-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.visual-config-guide__preset-icon {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.92);
  border: 1px solid rgba(191, 206, 241, 0.84);
  color: var(--color-button-primary, var(--color-primary));
  font-size: 1rem;
}

.visual-config-guide__preset-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(235, 244, 255, 0.95);
  border: 1px solid rgba(173, 196, 250, 0.86);
  color: #315aa7;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.visual-config-guide__preset-card h5 {
  margin: 0;
  color: var(--color-title, var(--primary));
  font-size: 1rem;
  line-height: 1.25;
}

.visual-config-guide__preset-card p {
  margin: 0;
  color: var(--color-text-secondary, var(--muted));
  font-size: 0.92rem;
  line-height: 1.55;
}

.visual-config-guide__checks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.visual-config-guide__checks li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid rgba(224, 230, 245, 0.78);
  color: var(--color-text, var(--text));
  font-size: 0.94rem;
  line-height: 1.45;
}

.visual-config-guide__check-icon {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: rgba(230, 238, 255, 0.95);
  border: 1px solid rgba(184, 201, 239, 0.88);
  color: var(--color-button-primary, var(--color-primary));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

@media (max-width: 1200px) {
  .visual-config-guide__preset-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .visual-config-guide__summary-pills,
  .visual-config-guide__checks {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .visual-config-guide__preset-grid,
  .visual-config-guide__summary-pills,
  .visual-config-guide__checks {
    grid-template-columns: 1fr;
  }

  .visual-config-guide__panel {
    padding: 18px;
  }
}

.operational-qa-guide {
  gap: 22px;
}

.operational-qa-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.operational-qa-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.operational-qa-guide__summary-pills i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  color: var(--color-button-primary, var(--color-primary));
  flex: 0 0 auto;
}

.operational-qa-guide__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.operational-qa-guide__card--access::after {
  background: linear-gradient(90deg, #6a99ff 0%, #3f78f0 100%);
}

.operational-qa-guide__card--flow::after {
  background: linear-gradient(90deg, #7f7cff 0%, #615df1 100%);
}

.operational-qa-guide__card--finance::after {
  background: linear-gradient(90deg, #50d4bf 0%, #18af97 100%);
}

.operational-qa-guide__card--delivery::after {
  background: linear-gradient(90deg, #ffb869 0%, #f39a2e 100%);
}

.operational-qa-guide__card--access .appearance-onboarding-icon,
.operational-qa-guide__card--access .operational-qa-guide__check,
.operational-qa-guide__card--access .operational-qa-guide__step {
  color: #2f6ef1;
  border-color: rgba(136, 174, 255, 0.85);
  background: rgba(236, 243, 255, 0.92);
}

.operational-qa-guide__card--flow .appearance-onboarding-icon,
.operational-qa-guide__card--flow .operational-qa-guide__check,
.operational-qa-guide__card--flow .operational-qa-guide__step {
  color: #615df1;
  border-color: rgba(185, 181, 255, 0.82);
  background: rgba(242, 241, 255, 0.94);
}

.operational-qa-guide__card--finance .appearance-onboarding-icon,
.operational-qa-guide__card--finance .operational-qa-guide__check,
.operational-qa-guide__card--finance .operational-qa-guide__step {
  color: #149d87;
  border-color: rgba(147, 232, 216, 0.84);
  background: rgba(236, 253, 249, 0.94);
}

.operational-qa-guide__card--delivery .appearance-onboarding-icon,
.operational-qa-guide__card--delivery .operational-qa-guide__check,
.operational-qa-guide__card--delivery .operational-qa-guide__step {
  color: #e08a1e;
  border-color: rgba(255, 209, 150, 0.84);
  background: rgba(255, 247, 235, 0.95);
}

.operational-qa-guide__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.operational-qa-guide__item span:last-child {
  min-width: 0;
}

@media (max-width: 1024px) {
  .operational-qa-guide__summary-pills,
  .operational-qa-guide__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .operational-qa-guide__summary-pills,
  .operational-qa-guide__grid {
    grid-template-columns: 1fr;
  }
}

.delivery-final-guide {
  gap: 22px;
}

.delivery-final-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.delivery-final-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.delivery-final-guide__summary-pills i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 241, 255, 0.9);
  border: 1px solid rgba(190, 206, 244, 0.82);
  color: var(--color-button-primary, var(--color-primary));
  flex: 0 0 auto;
}

.delivery-final-guide__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.delivery-final-guide__card--brand::after {
  background: linear-gradient(90deg, #6c97ff 0%, #4677f0 100%);
}

.delivery-final-guide__card--experience::after {
  background: linear-gradient(90deg, #a778ff 0%, #8657f1 100%);
}

.delivery-final-guide__card--operation::after {
  background: linear-gradient(90deg, #59d6b8 0%, #1dad8b 100%);
}

.delivery-final-guide__card--handoff::after {
  background: linear-gradient(90deg, #ffb770 0%, #f09c35 100%);
}

.delivery-final-guide__card--brand .appearance-onboarding-icon,
.delivery-final-guide__card--brand .delivery-final-guide__check,
.delivery-final-guide__card--brand .delivery-final-guide__step {
  color: #356ff0;
  border-color: rgba(140, 176, 255, 0.84);
  background: rgba(237, 244, 255, 0.92);
}

.delivery-final-guide__card--experience .appearance-onboarding-icon,
.delivery-final-guide__card--experience .delivery-final-guide__check,
.delivery-final-guide__card--experience .delivery-final-guide__step {
  color: #8352eb;
  border-color: rgba(201, 178, 255, 0.84);
  background: rgba(246, 240, 255, 0.94);
}

.delivery-final-guide__card--operation .appearance-onboarding-icon,
.delivery-final-guide__card--operation .delivery-final-guide__check,
.delivery-final-guide__card--operation .delivery-final-guide__step {
  color: #169a7c;
  border-color: rgba(154, 234, 213, 0.84);
  background: rgba(237, 253, 248, 0.94);
}

.delivery-final-guide__card--handoff .appearance-onboarding-icon,
.delivery-final-guide__card--handoff .delivery-final-guide__check,
.delivery-final-guide__card--handoff .delivery-final-guide__step {
  color: #df8b23;
  border-color: rgba(255, 213, 159, 0.84);
  background: rgba(255, 248, 236, 0.95);
}

.delivery-final-guide__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.delivery-final-guide__item span:last-child {
  min-width: 0;
}

.delivery-final-guide__closing {
  display: grid;
  gap: 8px;
  padding: 22px 24px;
  border-radius: 24px;
  border: 1px solid rgba(188, 223, 206, 0.92);
  background: linear-gradient(180deg, rgba(245, 255, 249, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.delivery-final-guide__closing h4 {
  margin: 0;
  color: #20775f;
  font-size: 1.18rem;
  line-height: 1.3;
}

.delivery-final-guide__closing p {
  margin: 0;
  color: #4c6b62;
  font-size: 0.94rem;
  line-height: 1.55;
}

.appearance-commercial-stage {
  gap: 22px;
}

.appearance-commercial-stage .appearance-onboarding-hero__copy {
  gap: 8px;
}

.appearance-commercial-stage .appearance-onboarding-hero__copy .section-title {
  max-width: 720px;
}

.appearance-commercial-stage .appearance-onboarding-hero__copy .section-subtitle {
  max-width: 760px;
}

.appearance-commercial-stage__label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(240, 245, 255, 0.94);
  border: 1px solid rgba(194, 209, 244, 0.9);
  color: var(--color-title, var(--primary));
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1;
}

.appearance-commercial-stage .appearance-onboarding-hero__note,
.appearance-commercial-stage .demo-ready-guide__hero,
.appearance-commercial-stage .demo-ready-guide__timeline-wrap,
.appearance-commercial-stage .demo-ready-guide__closing,
.appearance-commercial-stage .demo-commercial-guide__closing,
.appearance-commercial-stage .sales-arguments-guide__closing,
.appearance-commercial-stage .sales-presentation-checklist__closing {
  box-shadow: 0 12px 24px rgba(62, 79, 126, 0.07), inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.appearance-commercial-stage .appearance-onboarding-block {
  gap: 16px;
  min-height: 100%;
}

.appearance-commercial-stage .appearance-onboarding-list {
  gap: 8px;
}

.appearance-commercial-stage .appearance-onboarding-list li {
  padding: 8px 0;
}

.appearance-commercial-stage .appearance-onboarding-block__head h4 {
  font-size: 1rem;
}

.appearance-commercial-stage .appearance-onboarding-block__head p {
  max-width: 30ch;
}

.appearance-commercial-stage .appearance-onboarding-step {
  letter-spacing: 0.1em;
}

.appearance-commercial-stage .appearance-onboarding-icon {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76);
}

.appearance-commercial-stage .appearance-onboarding-hero__note,
.appearance-commercial-stage .demo-ready-guide__hero,
.appearance-commercial-stage .demo-ready-guide__timeline-wrap,
.appearance-commercial-stage .demo-ready-guide__closing,
.appearance-commercial-stage .demo-commercial-guide__closing,
.appearance-commercial-stage .sales-arguments-guide__closing,
.appearance-commercial-stage .sales-presentation-checklist__closing {
  position: relative;
  overflow: hidden;
}

.appearance-commercial-stage .appearance-onboarding-hero__note::after,
.appearance-commercial-stage .demo-ready-guide__hero::after,
.appearance-commercial-stage .demo-ready-guide__timeline-wrap::after,
.appearance-commercial-stage .demo-ready-guide__closing::after,
.appearance-commercial-stage .demo-commercial-guide__closing::after,
.appearance-commercial-stage .sales-arguments-guide__closing::after,
.appearance-commercial-stage .sales-presentation-checklist__closing::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(255, 255, 255, 0.42), transparent 42%);
  pointer-events: none;
}

.appearance-commercial-stage .demo-commercial-guide__summary-pills li,
.appearance-commercial-stage .sales-arguments-guide__summary-pills li,
.appearance-commercial-stage .demo-ready-guide__summary-pills li,
.appearance-commercial-stage .sales-presentation-checklist__summary-pills li {
  min-height: 58px;
}

.appearance-commercial-stage .demo-commercial-guide__closing h4,
.appearance-commercial-stage .sales-arguments-guide__closing h4 {
  font-size: 1.1rem;
}

.appearance-commercial-stage .demo-commercial-guide__closing p,
.appearance-commercial-stage .sales-arguments-guide__closing p,
.appearance-commercial-stage .demo-ready-guide__closing p,
.appearance-commercial-stage .sales-presentation-checklist__closing p {
  max-width: 74ch;
}

.demo-commercial-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.demo-commercial-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.demo-commercial-guide__summary-pills i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 241, 247, 0.94);
  border: 1px solid rgba(255, 202, 223, 0.84);
  color: #de4d90;
  flex: 0 0 auto;
}

.demo-commercial-guide__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.demo-commercial-guide__card--target::after {
  background: linear-gradient(90deg, #6c97ff 0%, #4677f0 100%);
}

.demo-commercial-guide__card--visual::after {
  background: linear-gradient(90deg, #ff8bbb 0%, #f35d97 100%);
}

.demo-commercial-guide__card--flows::after {
  background: linear-gradient(90deg, #58d7c4 0%, #1caf95 100%);
}

.demo-commercial-guide__card--message::after {
  background: linear-gradient(90deg, #b286ff 0%, #8656f1 100%);
}

.demo-commercial-guide__card--target .appearance-onboarding-icon,
.demo-commercial-guide__card--target .demo-commercial-guide__check,
.demo-commercial-guide__card--target .demo-commercial-guide__step {
  color: #356ff0;
  border-color: rgba(140, 176, 255, 0.84);
  background: rgba(237, 244, 255, 0.92);
}

.demo-commercial-guide__card--visual .appearance-onboarding-icon,
.demo-commercial-guide__card--visual .demo-commercial-guide__check,
.demo-commercial-guide__card--visual .demo-commercial-guide__step {
  color: #de4d90;
  border-color: rgba(255, 191, 218, 0.84);
  background: rgba(255, 242, 248, 0.95);
}

.demo-commercial-guide__card--flows .appearance-onboarding-icon,
.demo-commercial-guide__card--flows .demo-commercial-guide__check,
.demo-commercial-guide__card--flows .demo-commercial-guide__step {
  color: #169c83;
  border-color: rgba(154, 234, 213, 0.84);
  background: rgba(237, 253, 248, 0.94);
}

.demo-commercial-guide__card--message .appearance-onboarding-icon,
.demo-commercial-guide__card--message .demo-commercial-guide__check,
.demo-commercial-guide__card--message .demo-commercial-guide__step {
  color: #8352eb;
  border-color: rgba(201, 178, 255, 0.84);
  background: rgba(246, 240, 255, 0.94);
}

.demo-commercial-guide__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.demo-commercial-guide__item span:last-child {
  min-width: 0;
}

.demo-commercial-guide__closing {
  display: grid;
  gap: 8px;
  padding: 22px 24px;
  border-radius: 24px;
  border: 1px solid rgba(255, 205, 225, 0.88);
  background: linear-gradient(180deg, rgba(255, 245, 250, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.demo-commercial-guide__closing h4 {
  margin: 0;
  color: #b13f73;
  font-size: 1.18rem;
  line-height: 1.3;
}

.demo-commercial-guide__closing p {
  margin: 0;
  color: #735467;
  font-size: 0.94rem;
  line-height: 1.55;
}

.sales-arguments-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.sales-arguments-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.sales-arguments-guide__summary-pills i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(239, 243, 255, 0.94);
  border: 1px solid rgba(198, 210, 246, 0.84);
  color: #4c67d9;
  flex: 0 0 auto;
}

.sales-arguments-guide__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.sales-arguments-guide__card--manual::after {
  background: linear-gradient(90deg, #6c97ff 0%, #4677f0 100%);
}

.sales-arguments-guide__card--brand::after {
  background: linear-gradient(90deg, #ff9dc5 0%, #ef6a9d 100%);
}

.sales-arguments-guide__card--control::after {
  background: linear-gradient(90deg, #59d7c3 0%, #1cb197 100%);
}

.sales-arguments-guide__card--scale::after {
  background: linear-gradient(90deg, #ac89ff 0%, #855bf0 100%);
}

.sales-arguments-guide__card--manual .appearance-onboarding-icon,
.sales-arguments-guide__card--manual .sales-arguments-guide__check,
.sales-arguments-guide__card--manual .sales-arguments-guide__step {
  color: #356ff0;
  border-color: rgba(140, 176, 255, 0.84);
  background: rgba(237, 244, 255, 0.92);
}

.sales-arguments-guide__card--brand .appearance-onboarding-icon,
.sales-arguments-guide__card--brand .sales-arguments-guide__check,
.sales-arguments-guide__card--brand .sales-arguments-guide__step {
  color: #df5a92;
  border-color: rgba(255, 190, 217, 0.84);
  background: rgba(255, 243, 248, 0.95);
}

.sales-arguments-guide__card--control .appearance-onboarding-icon,
.sales-arguments-guide__card--control .sales-arguments-guide__check,
.sales-arguments-guide__card--control .sales-arguments-guide__step {
  color: #169b82;
  border-color: rgba(154, 234, 213, 0.84);
  background: rgba(237, 253, 248, 0.94);
}

.sales-arguments-guide__card--scale .appearance-onboarding-icon,
.sales-arguments-guide__card--scale .sales-arguments-guide__check,
.sales-arguments-guide__card--scale .sales-arguments-guide__step {
  color: #8352eb;
  border-color: rgba(201, 178, 255, 0.84);
  background: rgba(246, 240, 255, 0.94);
}

.sales-arguments-guide__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.sales-arguments-guide__item span:last-child {
  min-width: 0;
}

.sales-arguments-guide__closing {
  display: grid;
  gap: 8px;
  padding: 22px 24px;
  border-radius: 24px;
  border: 1px solid rgba(201, 214, 247, 0.88);
  background: linear-gradient(180deg, rgba(244, 247, 255, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.sales-arguments-guide__closing h4 {
  margin: 0;
  color: #4056b2;
  font-size: 1.18rem;
  line-height: 1.3;
}

.sales-arguments-guide__closing p {
  margin: 0;
  color: #5c6283;
  font-size: 0.94rem;
  line-height: 1.55;
}

.demo-ready-guide__hero {
  display: grid;
  gap: 18px;
  padding: 22px 24px;
  border-radius: 26px;
  border: 1px solid rgba(190, 223, 208, 0.9);
  background: linear-gradient(180deg, rgba(244, 255, 249, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: 0 14px 28px rgba(63, 118, 94, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.demo-ready-guide__hero-main {
  display: flex;
  align-items: center;
  gap: 18px;
}

.demo-ready-guide__hero-icon {
  width: 72px;
  height: 72px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: #249267;
  background: radial-gradient(circle at top left, rgba(232, 251, 241, 0.98), rgba(245, 255, 249, 0.98));
  border: 1px solid rgba(175, 221, 196, 0.9);
  font-size: 1.8rem;
}

.demo-ready-guide__hero-copy {
  display: grid;
  gap: 8px;
}

.demo-ready-guide__hero-copy h4,
.demo-ready-guide__hero-copy p {
  margin: 0;
}

.demo-ready-guide__hero-copy h4 {
  color: #20775f;
  font-size: 1.38rem;
  line-height: 1.2;
}

.demo-ready-guide__hero-copy p {
  color: #4c6b62;
  font-size: 0.94rem;
  line-height: 1.55;
  max-width: 760px;
}

.demo-ready-guide__hero-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(230, 248, 239, 0.96);
  border: 1px solid rgba(170, 215, 191, 0.9);
  color: #227b5f;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.demo-ready-guide__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.demo-ready-guide__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.demo-ready-guide__summary-pills li i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(233, 248, 241, 0.94);
  border: 1px solid rgba(181, 224, 202, 0.9);
  color: #269268;
  flex: 0 0 auto;
}

.demo-ready-guide__timeline-wrap {
  display: grid;
  gap: 16px;
  padding: 22px;
  border-radius: 24px;
  border: 1px solid rgba(197, 210, 241, 0.78);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(247, 250, 255, 0.98) 100%);
  box-shadow: 0 12px 24px rgba(67, 84, 128, 0.06);
}

.demo-ready-guide__timeline-head {
  display: grid;
  gap: 6px;
}

.demo-ready-guide__timeline-head p {
  margin: 0;
  color: var(--color-text-secondary, var(--muted));
  font-size: 0.9rem;
  line-height: 1.5;
}

.demo-ready-guide__timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.demo-ready-guide__timeline-step {
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 14px 12px;
  border-radius: 18px;
  border: 1px solid rgba(204, 216, 245, 0.88);
  background: rgba(255, 255, 255, 0.94);
  position: relative;
}

.demo-ready-guide__timeline-step::after {
  content: "";
  position: absolute;
  top: 27px;
  right: -13px;
  width: 14px;
  height: 2px;
  background: rgba(185, 211, 199, 0.9);
}

.demo-ready-guide__timeline-step:last-child::after {
  display: none;
}

.demo-ready-guide__timeline-index {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #249267;
  background: rgba(233, 248, 241, 0.94);
  border: 1px solid rgba(181, 224, 202, 0.9);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.demo-ready-guide__timeline-label {
  color: var(--color-title, var(--primary));
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.45;
}

.demo-ready-guide__closing {
  padding: 20px 24px;
  border-radius: 24px;
  border: 1px solid rgba(196, 223, 207, 0.9);
  background: linear-gradient(180deg, rgba(242, 255, 248, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.demo-ready-guide__closing p {
  margin: 0;
  color: #2f6553;
  font-size: 0.98rem;
  line-height: 1.6;
  font-weight: 600;
}

.sales-presentation-checklist__summary-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.sales-presentation-checklist__summary-pills li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(197, 212, 244, 0.92);
  color: var(--color-title, var(--primary));
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.sales-presentation-checklist__summary-pills li i {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 242, 255, 0.94);
  border: 1px solid rgba(194, 210, 246, 0.88);
  color: #4677f0;
  flex: 0 0 auto;
}

.sales-presentation-checklist__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.sales-presentation-checklist__card--problem::after {
  background: linear-gradient(90deg, #6e98ff 0%, #4878f0 100%);
}

.sales-presentation-checklist__card--solution::after {
  background: linear-gradient(90deg, #ffb16f 0%, #f09431 100%);
}

.sales-presentation-checklist__card--value::after {
  background: linear-gradient(90deg, #59d7c3 0%, #1cb197 100%);
}

.sales-presentation-checklist__card--next::after {
  background: linear-gradient(90deg, #b287ff 0%, #8658f1 100%);
}

.sales-presentation-checklist__card--problem .appearance-onboarding-icon,
.sales-presentation-checklist__card--problem .sales-presentation-checklist__check,
.sales-presentation-checklist__card--problem .sales-presentation-checklist__step {
  color: #356ff0;
  border-color: rgba(140, 176, 255, 0.84);
  background: rgba(237, 244, 255, 0.92);
}

.sales-presentation-checklist__card--solution .appearance-onboarding-icon,
.sales-presentation-checklist__card--solution .sales-presentation-checklist__check,
.sales-presentation-checklist__card--solution .sales-presentation-checklist__step {
  color: #de8625;
  border-color: rgba(255, 213, 159, 0.84);
  background: rgba(255, 247, 237, 0.95);
}

.sales-presentation-checklist__card--value .appearance-onboarding-icon,
.sales-presentation-checklist__card--value .sales-presentation-checklist__check,
.sales-presentation-checklist__card--value .sales-presentation-checklist__step {
  color: #169b82;
  border-color: rgba(154, 234, 213, 0.84);
  background: rgba(237, 253, 248, 0.94);
}

.sales-presentation-checklist__card--next .appearance-onboarding-icon,
.sales-presentation-checklist__card--next .sales-presentation-checklist__check,
.sales-presentation-checklist__card--next .sales-presentation-checklist__step {
  color: #8352eb;
  border-color: rgba(201, 178, 255, 0.84);
  background: rgba(246, 240, 255, 0.94);
}

.sales-presentation-checklist__check {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  border: 1px solid rgba(184, 201, 239, 0.88);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.sales-presentation-checklist__item span:last-child {
  min-width: 0;
}

.sales-presentation-checklist__closing {
  padding: 20px 24px;
  border-radius: 24px;
  border: 1px solid rgba(199, 216, 247, 0.9);
  background: linear-gradient(180deg, rgba(244, 248, 255, 0.98) 0%, rgba(255, 255, 255, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.sales-presentation-checklist__closing p {
  margin: 0;
  color: #43567b;
  font-size: 0.98rem;
  line-height: 1.6;
  font-weight: 600;
}

@media (max-width: 1024px) {
  .appearance-commercial-stage .appearance-onboarding-block__head p,
  .appearance-commercial-stage .demo-commercial-guide__closing p,
  .appearance-commercial-stage .sales-arguments-guide__closing p,
  .appearance-commercial-stage .demo-ready-guide__closing p,
  .appearance-commercial-stage .sales-presentation-checklist__closing p {
    max-width: none;
  }

  .sales-presentation-checklist__summary-pills,
  .sales-presentation-checklist__grid,
  .demo-ready-guide__summary-pills {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-ready-guide__timeline {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .demo-ready-guide__timeline-step::after {
    display: none;
  }

  .sales-arguments-guide__summary-pills,
  .sales-arguments-guide__grid,
  .demo-commercial-guide__summary-pills,
  .demo-commercial-guide__grid,
  .delivery-final-guide__summary-pills,
  .delivery-final-guide__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .appearance-commercial-stage {
    gap: 18px;
  }

  .appearance-commercial-stage .appearance-onboarding-hero__note,
  .appearance-commercial-stage .demo-commercial-guide__closing,
  .appearance-commercial-stage .sales-arguments-guide__closing,
  .appearance-commercial-stage .sales-presentation-checklist__closing {
    padding: 18px;
  }

  .appearance-commercial-stage__label {
    font-size: 0.7rem;
  }

  .demo-ready-guide__hero,
  .demo-ready-guide__timeline-wrap,
  .demo-ready-guide__closing {
    padding: 18px;
  }

  .demo-ready-guide__hero-main {
    align-items: flex-start;
    flex-direction: column;
  }

  .sales-presentation-checklist__summary-pills,
  .sales-presentation-checklist__grid,
  .demo-ready-guide__summary-pills,
  .demo-ready-guide__timeline {
    grid-template-columns: 1fr;
  }

  .sales-arguments-guide__summary-pills,
  .sales-arguments-guide__grid,
  .demo-commercial-guide__summary-pills,
  .demo-commercial-guide__grid,
  .delivery-final-guide__summary-pills,
  .delivery-final-guide__grid {
    grid-template-columns: 1fr;
  }

  .sales-presentation-checklist__closing,
  .sales-arguments-guide__closing,
  .demo-commercial-guide__closing,
  .delivery-final-guide__closing {
    padding: 18px;
  }
}

/* Sync applied preset themes with the same commercial button tokens used by Theme Builder previews. */
body.theme-blue {
  --color-button-primary: #1F3F8F;
  --color-button-primary-hover: #17316F;
  --color-button-primary-color: #FFFFFF;
  --color-button-secondary: #0F8B8D;
  --color-button-secondary-hover: #0B6E70;
  --color-button-secondary-color: #FFFFFF;
  --color-button-tertiary-text: #1F3F8F;
  --color-button-tertiary-border: #C7E7EA;
  --color-button-tertiary-bg: #FFFFFF;
  --color-button-tertiary-hover: #EDF8FA;
}

body.theme-green {
  --color-button-primary: #16695A;
  --color-button-primary-hover: #104E43;
  --color-button-primary-color: #FFFFFF;
  --color-button-secondary: #1F9E96;
  --color-button-secondary-hover: #177C75;
  --color-button-secondary-color: #FFFFFF;
  --color-button-tertiary-text: #16695A;
  --color-button-tertiary-border: #C9ECE3;
  --color-button-tertiary-bg: #FFFFFF;
  --color-button-tertiary-hover: #ECFAF8;
}

body.theme-minimal {
  --color-button-primary: #3E4D63;
  --color-button-primary-hover: #2F3C50;
  --color-button-primary-color: #FFFFFF;
  --color-button-secondary: #8A7461;
  --color-button-secondary-hover: #6F5E50;
  --color-button-secondary-color: #FFFFFF;
  --color-button-tertiary-text: #3E4D63;
  --color-button-tertiary-border: #DDD8D2;
  --color-button-tertiary-bg: #FFFFFF;
  --color-button-tertiary-hover: #F4F6F9;
}

body.theme-rose {
  --color-button-primary: #9B4F7F;
  --color-button-primary-hover: #7E3E66;
  --color-button-primary-color: #FFFFFF;
  --color-button-secondary: #C9785E;
  --color-button-secondary-hover: #AC6048;
  --color-button-secondary-color: #FFFFFF;
  --color-button-tertiary-text: #8A446C;
  --color-button-tertiary-border: #F1D2C8;
  --color-button-tertiary-bg: #FFFFFF;
  --color-button-tertiary-hover: #FDF1EC;
}

/* -------------------------------------------------------------------------- */
/* iPad validation pass / tablet vertical                                     */
/* -------------------------------------------------------------------------- */
/* Ajustes minimos validados para iPad 8va gen en vertical.
   - No reemplazan `tablet-app-mode`.
   - No redisenan pantallas profundas.
   - Solo mejoran login y dashboard/inicio para 810px aprox. */

@media (min-width: 576px) and (max-width: 899px) {
  .auth-page {
    padding: 24px 20px;
  }

  .auth-shell {
    width: min(100%, 560px);
    grid-template-columns: 1fr;
    gap: 1.25rem;
    justify-items: center;
    margin-inline: auto;
  }

  .auth-panel,
  .login-left,
  .auth-card {
    width: 100%;
    margin-inline: auto;
  }

  .auth-panel,
  .auth-card {
    padding: 1.5rem;
  }

  .login-left {
    max-width: 520px;
    display: grid;
    justify-items: center;
    text-align: center;
  }

  .auth-card {
    max-width: 430px;
  }

  .login-logo-wrapper {
    justify-content: center;
  }

  .auth-panel p,
  .login-description {
    max-width: none;
  }

  .auth-page .toast-container {
    top: calc(20px + env(safe-area-inset-top, 0px));
    width: auto;
    max-width: min(calc(100vw - 40px), 480px);
    justify-items: center;
  }

  .auth-page .toast-message {
    width: max-content;
    max-width: 100%;
    margin-inline: auto;
    padding-inline: 1.25rem;
    text-align: center;
    white-space: nowrap;
  }

  .login-disclaimer {
    position: static;
    transform: none;
    margin-top: 12px;
    opacity: 0.7;
  }
}

@media (min-width: 768px) and (max-width: 899px) {
  .auth-page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
    align-items: center;
    justify-content: flex-start;
    row-gap: 0;
    padding-top: 28px;
    padding-bottom: 18px;
  }

  .auth-shell {
    width: min(100%, 520px);
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1.1rem;
  }

  .login-left {
    max-width: 440px;
    width: 100%;
    flex: 0 0 auto;
    gap: 0.5rem;
    padding-top: 0;
    padding-bottom: 0.35rem;
  }

  .login-logo {
    max-width: 220px;
    max-height: 96px;
    margin-bottom: 12px;
  }

  .login-description {
    max-width: 30ch;
    font-size: 0.95rem;
    line-height: 1.45;
  }

  .auth-card {
    max-width: 410px;
    width: 100%;
  }

  .login-footer-row {
    margin-top: 10px;
  }

  .login-disclaimer {
    margin-top: auto;
    align-self: center;
    text-align: center;
    padding-top: 12px;
    padding-bottom: 2px;
  }
}

/* iPad portrait login final override */
@media (min-width: 768px) and (max-width: 899px) and (orientation: portrait) {
  .auth-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100dvh;
    padding: 36px 24px 56px;
    overflow: hidden;
  }

  .auth-shell {
    width: min(100%, 460px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    flex: 0 0 auto;
    gap: 40px;
    margin: 0 auto;
    padding-top: 80px;
  }

  .login-left {
    max-width: 430px;
    width: 100%;
    padding: 0;
    display: grid;
    justify-items: center;
    text-align: center;
  }

  .login-logo-wrapper {
    justify-content: center;
  }

  .login-logo {
    width: min(100%, 390px);
    max-width: 390px;
    max-height: 118px;
    margin-bottom: 12px;
    object-fit: contain;
  }

  .login-description {
    margin: 0;
    max-width: 42ch;
    text-align: center;
    font-size: 15px;
    line-height: 1.45;
  }

  .auth-card {
    width: 100%;
    max-width: 410px;
    margin-top: 8px;
    padding: 24px 18px;
  }

  .login-disclaimer {
    position: fixed;
    left: 50%;
    bottom: calc(14px + env(safe-area-inset-bottom, 0px));
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100vw - 48px);
    margin: 0;
    padding: 0;
    text-align: center;
    white-space: nowrap;
    opacity: 0.62;
    font-size: 12px;
    pointer-events: none;
  }

  .auth-page .toast-container {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100vw - 48px);
  }

  .auth-page .toast-message {
    width: max-content;
    max-width: calc(100vw - 48px);
    white-space: nowrap;
    text-align: center;
  }
}

/* -------------------------------------------------------------------------- */
/* Tablet shell final overrides                                               */
/* -------------------------------------------------------------------------- */
/* Compatibilidad segura con `tablet-app-mode` en html o body.
   Estos overrides solo ordenan el shell global para tablet-first y no
   reemplazan reglas historicas ni layouts por modulo. */

@media (min-width: 768px) and (max-width: 1199px) {
  .tablet-app-mode .dashboard-frame {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: clamp(12px, 1.8vw, 18px);
    overflow-x: hidden;
    overflow-y: visible;
  }

  .tablet-app-mode .dashboard-shell,
  .tablet-app-mode .app-layout {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    border-radius: 28px;
    overflow: visible;
  }

  .tablet-app-mode .dashboard-main,
  .tablet-app-mode .main-content {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: clamp(14px, 1.8vw, 20px) clamp(14px, 1.8vw, 20px) calc(112px + env(safe-area-inset-bottom, 0px));
    overflow-x: hidden;
    overflow-y: visible;
    box-sizing: border-box;
  }

  .tablet-app-mode .content-area,
  .tablet-app-mode .page-content {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding-right: 0;
    padding-left: 0;
    padding-bottom: 0;
    overflow-x: hidden;
    overflow-y: visible;
    box-sizing: border-box;
  }

  .tablet-app-mode .content-area > *,
  .tablet-app-mode .page-content > * {
    min-width: 0;
    max-width: 100%;
  }

  .tablet-app-mode .topbar,
  .tablet-app-mode .mobile-page-header {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    margin-bottom: 16px;
  }

  .tablet-app-mode .notifications-dropdown,
  .tablet-app-mode .mobile-page-header .notifications-dropdown {
    max-width: min(360px, calc(100vw - 36px));
  }

  .tablet-app-mode .mobile-bottom-nav {
    left: max(12px, env(safe-area-inset-left, 0px));
    right: max(12px, env(safe-area-inset-right, 0px));
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-width: min(920px, calc(100vw - 24px));
    margin-inline: auto;
  }

  .tablet-app-mode .mobile-more-sheet {
    left: max(16px, env(safe-area-inset-left, 0px));
    right: max(16px, env(safe-area-inset-right, 0px));
    bottom: calc(92px + env(safe-area-inset-bottom, 0px));
    width: auto;
    max-width: min(680px, calc(100vw - 32px));
    margin-inline: auto;
  }
}

@media (min-width: 768px) and (max-width: 899px) {
  .tablet-app-mode .dashboard-main,
  .tablet-app-mode .main-content {
    padding-bottom: calc(116px + env(safe-area-inset-bottom, 0px));
  }

  .tablet-app-mode .content-area,
  .tablet-app-mode .page-content {
    gap: 14px;
  }

  .tablet-app-mode .topbar,
  .tablet-app-mode .mobile-page-header {
    border-radius: 24px;
  }

  .tablet-app-mode .mobile-bottom-nav {
    max-width: calc(100vw - 24px);
  }
}

@media (min-width: 900px) and (max-width: 1199px) {
  .tablet-app-mode .dashboard-main,
  .tablet-app-mode .main-content {
    padding-bottom: calc(108px + env(safe-area-inset-bottom, 0px));
  }

  .tablet-app-mode .content-area,
  .tablet-app-mode .page-content {
    gap: 16px;
  }

  .tablet-app-mode .mobile-bottom-nav {
    max-width: min(960px, calc(100vw - 36px));
  }

  .tablet-app-mode .mobile-more-sheet {
    max-width: min(760px, calc(100vw - 40px));
  }
}

/* Tablet toast readability override */
@media (min-width: 768px) and (max-width: 1199px) {
    .toast-container {
        width: auto !important;
        max-width: calc(100vw - 48px) !important;
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        top: max(12px, calc(env(safe-area-inset-top, 0px) + 12px)) !important;
        display: grid !important;
        justify-items: center !important;
    }

    .toast-message:not(.mobile-toast),
    .flash-message,
    .alert {
        display: block !important;
        width: fit-content !important;
        min-width: 280px !important;
        max-width: min(520px, calc(100vw - 48px)) !important;
        min-height: auto !important;
        padding: 14px 22px !important;
        text-align: center !important;
        white-space: normal !important;
        overflow-wrap: normal !important;
        word-break: normal !important;
        line-height: 1.35 !important;
        box-sizing: border-box !important;
    }

    .mobile-toast {
        width: fit-content !important;
        min-width: 320px !important;
        max-width: min(560px, calc(100vw - 48px)) !important;
        min-height: 56px !important;
        display: grid !important;
        grid-template-columns: 36px minmax(0, 1fr) 36px !important;
        align-items: center !important;
    }

    .mobile-toast-content {
        white-space: normal !important;
        overflow-wrap: normal !important;
        word-break: normal !important;
        line-height: 1.28 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }
}

/* Tablet header/nav spacing final override */
@media (min-width: 768px) and (max-width: 899px) {
    .tablet-app-mode .topbar,
    .tablet-app-mode .mobile-page-header {
        grid-template-columns: minmax(0, 1fr) auto !important;
        grid-template-areas:
            "copy actions"
            "cta cta" !important;
        gap: 12px !important;
        padding: 14px 15px !important;
        margin-bottom: 14px !important;
        border-radius: 22px !important;
    }

    .tablet-app-mode .topbar-copy,
    .tablet-app-mode .mobile-page-header .topbar-copy {
        display: grid !important;
        gap: 4px !important;
        min-width: 0 !important;
    }

    .tablet-app-mode .topbar-title,
    .tablet-app-mode .page-title,
    .tablet-app-mode .mobile-page-title {
        font-size: clamp(1.55rem, 3.5vw, 1.95rem) !important;
        line-height: 1.08 !important;
    }

    .tablet-app-mode .topbar-greeting,
    .tablet-app-mode .mobile-greeting,
    .tablet-app-mode .topbar-subtitle,
    .tablet-app-mode .page-subtitle,
    .tablet-app-mode .mobile-header-subtitle,
    .tablet-app-mode .topbar-copy p {
        line-height: 1.3 !important;
    }

    .tablet-app-mode .topbar-subtitle,
    .tablet-app-mode .page-subtitle,
    .tablet-app-mode .mobile-header-subtitle,
    .tablet-app-mode .topbar-copy p {
        font-size: 12px !important;
    }

    .tablet-app-mode .header-top-row,
    .tablet-app-mode .mobile-page-header .header-top-row,
    .tablet-app-mode .mobile-page-header .mobile-header-top-row {
        gap: 10px !important;
        align-items: center !important;
    }

    .tablet-app-mode .header-datetime,
    .tablet-app-mode .mobile-header-time-block {
        min-width: max-content !important;
        margin-top: 0 !important;
    }

    .tablet-app-mode .notification-button,
    .tablet-app-mode .mobile-page-header .notification-button {
        width: 40px !important;
        height: 40px !important;
    }

    .tablet-app-mode .header-main-button,
    .tablet-app-mode .mobile-primary-cta-shell {
        width: 100% !important;
    }

    .tablet-app-mode .header-main-button .btn,
    .tablet-app-mode .header-main-button > a.btn,
    .tablet-app-mode .header-main-button > button.btn,
    .tablet-app-mode .mobile-primary-cta,
    .tablet-app-mode .btn-nueva-orden {
        width: 100% !important;
        min-height: 44px !important;
        margin-top: 2px !important;
    }

    .tablet-app-mode .dashboard-main,
    .tablet-app-mode .main-content {
        padding-bottom: calc(100px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .tablet-app-mode .content-area,
    .tablet-app-mode .page-content {
        padding-bottom: 8px !important;
        scroll-padding-bottom: calc(116px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .tablet-app-mode .notifications-dropdown,
    .tablet-app-mode .mobile-page-header .notifications-dropdown {
        width: min(340px, calc(100vw - 32px)) !important;
        max-height: min(420px, calc(100dvh - 150px)) !important;
        overflow-y: auto !important;
    }

    .tablet-app-mode .mobile-more-sheet {
        bottom: calc(88px + env(safe-area-inset-bottom, 0px)) !important;
        max-height: min(62vh, calc(100dvh - 132px)) !important;
        overflow-y: auto !important;
    }
}

@media (min-width: 900px) and (max-width: 1199px) {
    .tablet-app-mode .topbar,
    .tablet-app-mode .mobile-page-header {
        gap: 14px !important;
        padding: 16px 18px !important;
        margin-bottom: 16px !important;
    }

    .tablet-app-mode .topbar-title,
    .tablet-app-mode .page-title,
    .tablet-app-mode .mobile-page-title {
        font-size: clamp(1.75rem, 3vw, 2.2rem) !important;
        line-height: 1.08 !important;
    }

    .tablet-app-mode .topbar-subtitle,
    .tablet-app-mode .page-subtitle,
    .tablet-app-mode .mobile-header-subtitle,
    .tablet-app-mode .topbar-copy p {
        font-size: 13px !important;
        line-height: 1.35 !important;
    }

    .tablet-app-mode .header-top-row {
        gap: 12px !important;
        align-items: center !important;
    }

    .tablet-app-mode .header-main-button,
    .tablet-app-mode .mobile-primary-cta-shell {
        width: auto !important;
        min-width: 220px !important;
    }

    .tablet-app-mode .header-main-button .btn,
    .tablet-app-mode .header-main-button > a.btn,
    .tablet-app-mode .header-main-button > button.btn,
    .tablet-app-mode .mobile-primary-cta,
    .tablet-app-mode .btn-nueva-orden {
        min-width: 220px !important;
        width: auto !important;
    }

    .tablet-app-mode .dashboard-main,
    .tablet-app-mode .main-content {
        padding-bottom: calc(90px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .tablet-app-mode .content-area,
    .tablet-app-mode .page-content {
        scroll-padding-bottom: calc(108px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .tablet-app-mode .notifications-dropdown,
    .tablet-app-mode .mobile-page-header .notifications-dropdown {
        width: min(360px, calc(100vw - 40px)) !important;
        max-height: min(430px, calc(100dvh - 160px)) !important;
        overflow-y: auto !important;
    }

    .tablet-app-mode .mobile-more-sheet {
        bottom: calc(92px + env(safe-area-inset-bottom, 0px)) !important;
        max-height: min(66vh, calc(100dvh - 140px)) !important;
        overflow-y: auto !important;
    }
}

/* Tablet more sheet fit-content override */
@media (min-width: 768px) and (max-width: 1199px) {
    .tablet-app-mode .mobile-more-sheet,
    html.tablet-app-mode .mobile-more-sheet,
    body.tablet-app-mode .mobile-more-sheet {
        width: min(680px, calc(100vw - 64px)) !important;
        left: 50% !important;
        right: auto !important;
        bottom: calc(92px + env(safe-area-inset-bottom, 0px)) !important;
        transform: translateX(-50%) !important;
        height: auto !important;
        max-height: calc(100dvh - 150px) !important;
        overflow-y: visible !important;
        overflow-x: hidden !important;
        padding-bottom: 16px !important;
    }

    .tablet-app-mode .mobile-more-sheet-links,
    html.tablet-app-mode .mobile-more-sheet-links,
    body.tablet-app-mode .mobile-more-sheet-links {
        overflow: visible !important;
        max-height: none !important;
    }
}

/* Dashboard content tablet/mobile compact layout */
@media (min-width: 768px) and (max-width: 1199px) {
    .dashboard-hero-inline {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) auto !important;
        align-items: center !important;
        gap: 18px !important;
        padding: 20px 22px !important;
        min-height: auto !important;
    }

    .dashboard-hero-inline .section-header {
        margin-bottom: 0 !important;
    }

    .dashboard-hero-inline .section-title {
        margin-bottom: 6px !important;
    }

    .dashboard-hero-inline .section-subtitle {
        margin: 0 !important;
    }

    .dashboard-hero-inline .dashboard-hero-content {
        min-width: 0 !important;
    }

    .dashboard-hero-inline .dashboard-user-card {
        width: auto !important;
        min-width: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
    }

    .dashboard-hero-inline .dashboard-user-meta {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: flex-end !important;
        gap: 12px !important;
        min-height: 46px !important;
        padding: 0 18px !important;
        border-radius: 999px !important;
        background: rgba(255, 255, 255, 0.78) !important;
        border: 1px solid rgba(190, 220, 230, 0.9) !important;
        white-space: nowrap !important;
    }

    .dashboard-metrics-compact {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .dashboard-metrics-compact .metric-card {
        min-height: 72px !important;
        padding: 16px 20px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 18px !important;
    }

    .dashboard-metrics-compact .metric-label {
        margin: 0 !important;
        line-height: 1.2 !important;
        text-align: left !important;
        max-width: 70% !important;
    }

    .dashboard-metrics-compact .metric-value {
        margin: 0 !important;
        font-size: clamp(28px, 4vw, 38px) !important;
        line-height: 1 !important;
        text-align: right !important;
        white-space: nowrap !important;
    }
}

@media (max-width: 767px) {
    .dashboard-hero-inline {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    .dashboard-hero-inline .dashboard-user-card {
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .dashboard-hero-inline .dashboard-user-meta {
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        flex-wrap: wrap !important;
        gap: 10px !important;
        white-space: normal !important;
    }

    .dashboard-metrics-compact {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    .dashboard-metrics-compact .metric-card {
        min-height: 68px !important;
        padding: 15px 18px !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 14px !important;
    }

    .dashboard-metrics-compact .metric-label {
        margin: 0 !important;
        line-height: 1.2 !important;
        text-align: left !important;
        max-width: 70% !important;
    }

    .dashboard-metrics-compact .metric-value {
        margin: 0 !important;
        font-size: clamp(26px, 8vw, 34px) !important;
        line-height: 1 !important;
        text-align: right !important;
        white-space: nowrap !important;
    }
}

/* Tablet landscape login balance override */
@media (min-width: 900px) and (max-width: 1199px) and (orientation: landscape) {
    .auth-page {
        min-height: 100vh !important;
        min-height: 100dvh !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 40px 56px 64px !important;
        overflow: hidden !important;
    }

    .auth-shell {
        width: min(100%, 900px) !important;
        display: grid !important;
        grid-template-columns: minmax(300px, 0.9fr) minmax(360px, 430px) !important;
        align-items: center !important;
        justify-content: center !important;
        gap: clamp(56px, 8vw, 96px) !important;
        margin: 0 auto !important;
        transform: translateY(-10px) !important;
    }

    .login-left {
        width: 100% !important;
        max-width: 360px !important;
        padding: 0 !important;
        margin: 0 !important;
        display: grid !important;
        justify-items: start !important;
        text-align: left !important;
    }

    .login-logo-wrapper {
        justify-content: flex-start !important;
    }

    .login-logo {
        width: min(100%, 340px) !important;
        max-width: 340px !important;
        max-height: 128px !important;
        margin-bottom: 18px !important;
        object-fit: contain !important;
    }

    .login-description {
        max-width: 32ch !important;
        margin: 0 !important;
        font-size: 0.96rem !important;
        line-height: 1.45 !important;
        text-align: left !important;
    }

    .auth-card {
        width: 100% !important;
        max-width: 430px !important;
        margin: 0 !important;
    }

    .login-disclaimer {
        position: fixed !important;
        left: 50% !important;
        bottom: calc(14px + env(safe-area-inset-bottom, 0px)) !important;
        transform: translateX(-50%) !important;
        margin: 0 !important;
        text-align: center !important;
        white-space: nowrap !important;
    }
}

@media (min-width: 1200px) {
  .dashboard-page-shell .dashboard-audit-card {
    height: auto !important;
    min-height: 0 !important;
    align-self: start !important;
  }

  .dashboard-page-shell .dashboard-audit-header {
    align-items: center !important;
  }

  .dashboard-page-shell .dashboard-audit-card > .dashboard-audit-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
    margin-top: 14px !important;
    align-items: stretch !important;
  }

  .dashboard-page-shell .dashboard-audit-card > .dashboard-audit-grid > .general-summary-item {
    min-width: 0 !important;
    min-height: 72px !important;
    height: auto !important;
    padding: 12px 14px !important;
    display: grid !important;
    grid-template-columns: 32px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 9px !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  .dashboard-page-shell .dashboard-audit-card .dashboard-audit-metric-icon {
    width: 32px !important;
    height: 32px !important;
    display: inline-grid !important;
    place-items: center !important;
    border-radius: 10px !important;
    font-size: 0.78rem !important;
  }

  .dashboard-page-shell .dashboard-audit-card .info-chip-label {
    min-width: 0 !important;
    margin: 0 !important;
    line-height: 1.15 !important;
    text-align: left !important;
  }

  .dashboard-page-shell .dashboard-audit-card .general-summary-item strong {
    justify-self: end !important;
    margin: 0 !important;
    font-size: 1.45rem !important;
    line-height: 1 !important;
  }

  .dashboard-page-shell .dashboard-audit-card .kpi-card--audit-missing .dashboard-audit-metric-icon {
    background: rgba(255, 239, 205, 0.9) !important;
    color: #bd7b1e !important;
  }

  .dashboard-page-shell .dashboard-audit-card .kpi-card--audit-debt .dashboard-audit-metric-icon {
    background: rgba(255, 231, 237, 0.9) !important;
    color: #bf5270 !important;
  }

  .dashboard-page-shell .dashboard-audit-card .kpi-card--audit-edited .dashboard-audit-metric-icon {
    background: rgba(234, 237, 255, 0.92) !important;
    color: #596db8 !important;
  }

  .dashboard-page-shell .dashboard-audit-card .kpi-card--audit-cancelled .dashboard-audit-metric-icon {
    background: rgba(255, 232, 236, 0.9) !important;
    color: #c24e62 !important;
  }
}

@media (min-width: 768px) and (max-width: 1199px) {
  .dashboard-page-shell .dashboard-audit-card > .dashboard-audit-grid > .general-summary-item {
    grid-template-columns: 32px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 9px !important;
  }

  .dashboard-page-shell .dashboard-audit-card .dashboard-audit-metric-icon {
    width: 32px !important;
    height: 32px !important;
    display: inline-grid !important;
    place-items: center !important;
    border-radius: 10px !important;
  }
}

@media (max-width: 767px) {
  .dashboard-page-shell .dashboard-audit-card > .dashboard-audit-grid > .general-summary-item {
    grid-template-columns: 32px minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 8px !important;
  }

  .dashboard-page-shell .dashboard-audit-card .dashboard-audit-metric-icon {
    width: 30px !important;
    height: 30px !important;
    display: inline-grid !important;
    place-items: center !important;
    border-radius: 9px !important;
  }
}

@media (min-width: 1200px) {
  .dashboard-insights-grid {
    align-items: stretch !important;
  }

  .dashboard-insights-grid > .content-card {
    height: auto !important;
    min-height: 0 !important;
    align-self: stretch !important;
  }

  .dashboard-insights-grid > .dashboard-indicators-card,
  .dashboard-insights-grid > .dashboard-orders-status-card {
    min-height: 0 !important;
  }

  .dashboard-insights-grid > .dashboard-indicators-card .chart-shell {
    flex: 0 0 auto !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-orders-status-body {
    flex: 0 0 auto !important;
    align-content: start !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-orders-status-header {
    margin-bottom: 28px !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-status-mini-metrics {
    margin-top: 24px !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-status-mini {
    width: 100% !important;
    min-height: 84px !important;
    padding: 16px 12px !important;
    box-sizing: border-box !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-status-mini-copy strong {
    font-size: 1.65rem !important;
    line-height: 1 !important;
  }

  .dashboard-insights-grid > .dashboard-orders-status-card .dashboard-status-mini-copy small {
    font-size: 0.76rem !important;
    line-height: 1.15 !important;
  }

  .dashboard-recent-orders-list {
    flex: 1 1 auto !important;
    gap: 4px !important;
    align-content: space-between !important;
  }

  .dashboard-recent-orders-list > .dashboard-recent-order {
    min-height: 56px !important;
    padding: 8px 10px !important;
    box-sizing: border-box !important;
  }
}

@media (min-width: 768px) {
  .dashboard-insights-grid > .dashboard-indicators-card .chart-shell {
    flex: 0 0 auto !important;
    min-height: 0 !important;
    margin-bottom: 0 !important;
  }
}

.dashboard-recent-orders-card .dashboard-recent-orders-list > .dashboard-recent-order:nth-child(n + 6) {
  display: none !important;
}

@media (min-width: 900px) and (max-width: 1199px) and (orientation: landscape) {
  .dashboard-recent-orders-card .dashboard-recent-orders-list > .dashboard-recent-order:nth-child(6) {
    display: grid !important;
  }
}

/* Tablet landscape login true center override */
@media (min-width: 900px) and (max-width: 1199px) and (orientation: landscape) {
  body.auth-page {
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    padding: 0 !important;
    overflow: hidden !important;
    display: block !important;
  }

  body.auth-page .auth-shell {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    width: min(900px, calc(100vw - 96px)) !important;
    max-width: 900px !important;
    display: grid !important;
    grid-template-columns: minmax(300px, 0.9fr) minmax(360px, 430px) !important;
    align-items: center !important;
    justify-content: center !important;
    gap: clamp(56px, 8vw, 96px) !important;
    margin: 0 !important;
    transform: translate(-50%, -50%) !important;
  }

  body.auth-page .auth-shell.fade-in {
    animation: none !important;
    opacity: 1 !important;
    transform: translate(-50%, -50%) !important;
  }

  body.auth-page .login-left {
    width: 100% !important;
    max-width: 360px !important;
    padding: 0 !important;
    margin: 0 !important;
    display: grid !important;
    justify-items: start !important;
    text-align: left !important;
  }

  body.auth-page .login-logo-wrapper {
    justify-content: flex-start !important;
  }

  body.auth-page .login-logo {
    width: min(100%, 340px) !important;
    max-width: 340px !important;
    max-height: 128px !important;
    margin-bottom: 18px !important;
    object-fit: contain !important;
  }

  body.auth-page .login-description {
    max-width: 32ch !important;
    margin: 0 !important;
    font-size: 0.96rem !important;
    line-height: 1.45 !important;
    text-align: left !important;
  }

  body.auth-page .auth-card {
    width: 100% !important;
    max-width: 430px !important;
    margin: 0 !important;
  }

  body.auth-page .login-disclaimer {
    position: fixed !important;
    left: 50% !important;
    bottom: calc(14px + env(safe-area-inset-bottom, 0px)) !important;
    transform: translateX(-50%) !important;
    margin: 0 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }
}

/* Tablet landscape dashboard header CTA and quick links override */
@media (min-width: 900px) and (max-width: 1199px) and (orientation: landscape) {
  body.tablet-app-mode .topbar,
  html.tablet-app-mode .topbar,
  .tablet-app-mode .topbar {
    align-items: stretch !important;
  }

  body.tablet-app-mode .header-main-button,
  html.tablet-app-mode .header-main-button,
  .tablet-app-mode .header-main-button {
    display: flex !important;
    width: 100% !important;
  }

  body.tablet-app-mode .header-main-button .btn,
  body.tablet-app-mode .header-main-button > a.btn,
  body.tablet-app-mode .header-main-button > button.btn,
  html.tablet-app-mode .header-main-button .btn,
  html.tablet-app-mode .header-main-button > a.btn,
  html.tablet-app-mode .header-main-button > button.btn,
  .tablet-app-mode .header-main-button .btn,
  .tablet-app-mode .header-main-button > a.btn,
  .tablet-app-mode .header-main-button > button.btn {
    width: 100% !important;
    max-width: none !important;
    justify-content: center !important;
  }

  body.tablet-app-mode .topbar-actions,
  html.tablet-app-mode .topbar-actions,
  .tablet-app-mode .topbar-actions {
    min-width: 0 !important;
  }

  body.tablet-app-mode .quick-links-grid,
  html.tablet-app-mode .quick-links-grid,
  .tablet-app-mode .quick-links-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 18px !important;
  }

  body.tablet-app-mode .quick-link-card,
  html.tablet-app-mode .quick-link-card,
  .tablet-app-mode .quick-link-card {
    min-width: 0 !important;
  }
}

/* Tablet portrait dashboard quick links list override */
@media (min-width: 768px) and (max-width: 899px) and (orientation: portrait) {
  body.tablet-app-mode .quick-links-grid,
  html.tablet-app-mode .quick-links-grid,
  .tablet-app-mode .quick-links-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 16px !important;
    margin-top: 10px;
  }

  body.tablet-app-mode .quick-link-card,
  html.tablet-app-mode .quick-link-card,
  .tablet-app-mode .quick-link-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 16px !important;
    width: 100% !important;
    min-height: 86px !important;
    padding: 16px 18px !important;
    text-align: left !important;
  }

  body.tablet-app-mode .quick-link-icon,
  html.tablet-app-mode .quick-link-icon,
  .tablet-app-mode .quick-link-icon {
    width: 52px !important;
    height: 52px !important;
    min-width: 52px !important;
    min-height: 52px !important;
    flex: 0 0 52px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
  }

  body.tablet-app-mode .quick-link-card > div,
  html.tablet-app-mode .quick-link-card > div,
  .tablet-app-mode .quick-link-card > div {
    min-width: 0 !important;
    display: grid !important;
    gap: 4px !important;
  }

  body.tablet-app-mode .quick-link-title,
  html.tablet-app-mode .quick-link-title,
  .tablet-app-mode .quick-link-title {
    margin: 0 !important;
    line-height: 1.2 !important;
  }

  body.tablet-app-mode .quick-link-text,
  html.tablet-app-mode .quick-link-text,
  .tablet-app-mode .quick-link-text {
    margin: 0 !important;
    line-height: 1.35 !important;
  }
}

/* Mobile dashboard hero meta stack override */
@media (max-width: 767px) {
  .dashboard-hero-inline {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 18px 16px !important;
  }

  .dashboard-hero-inline .dashboard-hero-content {
    min-width: 0 !important;
  }

  .dashboard-hero-inline .section-header {
    margin-bottom: 0 !important;
  }

  .dashboard-hero-inline .section-title {
    margin-bottom: 4px !important;
  }

  .dashboard-hero-inline .section-subtitle {
    margin: 0 !important;
    font-size: 13px !important;
    line-height: 1.25 !important;
  }

  .dashboard-hero-inline .dashboard-user-card {
    width: auto !important;
    min-width: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    justify-self: end !important;
  }

  .dashboard-hero-inline .dashboard-user-meta {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 4px !important;
    justify-items: end !important;
    align-items: center !important;
    min-height: auto !important;
    padding: 8px 10px !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, 0.78) !important;
    border: 1px solid rgba(190, 220, 230, 0.9) !important;
    white-space: nowrap !important;
    text-align: right !important;
  }

  .dashboard-hero-inline .dashboard-user-meta .divider {
    display: block !important;
    width: 100% !important;
    height: 1px !important;
    min-height: 1px !important;
    background: rgba(74, 88, 153, 0.18) !important;
    margin: 1px 0 !important;
  }

  .dashboard-hero-inline .dashboard-user-meta span {
    font-size: 12px !important;
    line-height: 1.15 !important;
  }

  .dashboard-hero-inline .dashboard-user-meta strong {
    font-size: 12px !important;
    font-weight: 700 !important;
  }
}