/* Contenedor */
.jm-wrap {
    padding: 20px 24px;
}

/* Header */
.jm-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}

.jm-title {
    font-size: 28px;
    font-weight: 600;
    color: #ff3b30;
    /* rojo tipo toteat */
    margin: 0;
}

/* Botones */
.jm-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.jm-btn {
    border: 0;
    padding: 10px 14px;
    border-radius: 999px;
    background: #1f1f1f;
    color: #fff;
    cursor: pointer;
    font-weight: 600;
}

.jm-btn:hover {
    filter: brightness(1.1);
}

.jm-btn-primary {
    background: #ff3b30;
}

.jm-btn-sm {
    padding: 8px 12px;
    font-size: 12px;
}

/* Tabs */
.jm-tabs {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid #eee;
    margin-bottom: 14px;
}

.jm-tab {
    border: 0;
    background: transparent;
    padding: 12px 14px;
    cursor: pointer;
    font-weight: 700;
    color: #333;
    border-bottom: 3px solid transparent;
}

.jm-tab.active {
    color: #ff3b30;
    border-bottom-color: #ff3b30;
}

.jm-hidden {
    display: none;
}

/* Card */
.jm-card {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 14px;
    padding: 14px;
}

.jm-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.jm-card-title {
    font-size: 18px;
    font-weight: 800;
    color: #111;
}

.jm-muted {
    color: #666;
}

.jm-hint {
    margin-top: 10px;
    font-size: 12px;
    color: #666;
}

/* Table */
.jm-table-wrap {
    overflow-x: auto;
}

.jm-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 980px;
}

.jm-table thead th {
    text-align: left;
    font-size: 13px;
    font-weight: 700;
    color: #111827 !important;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.jm-table tbody td {
    padding: 10px;
    border-bottom: 1px solid #f2f2f2;
    vertical-align: middle;
}

.jm-row.jm-new {
    background: #fff7f6;
}

.jm-center {
    text-align: center;
}

/* Inputs */
.jm-input,
.jm-select {
    width: 100%;
    height: 38px;
    border-radius: 10px;
    border: 1px solid #ddd;
    padding: 8px 10px;
    outline: none;
    background: #fff;
}

.jm-input:focus,
.jm-select:focus {
    border-color: #ff3b30;
    box-shadow: 0 0 0 3px rgba(255, 59, 48, 0.12);
}

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

/* Icon buttons */
.jm-icon-btn {
    border: 0;
    background: #ff3b30;
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
}

.jm-icon-btn:hover {
    filter: brightness(1.05);
}

.jm-icon-btn.danger {
    background: #111;
}

/* Toast */
.jm-toast {
    position: fixed;
    right: 18px;
    bottom: 18px;
    background: #111;
    color: #fff;
    padding: 12px 14px;
    border-radius: 12px;
    opacity: 0;
    transform: translateY(10px);
    transition: all .2s ease;
    z-index: 99999;
    max-width: 460px;
    font-weight: 700;
}

.jm-toast.show {
    opacity: 1;
    transform: translateY(0);
}

.jm-toast.ok {
    background: #16a34a;
}

.jm-toast.bad {
    background: #dc2626;
}


/* Placeholder gris */
.jm-input::placeholder {
    color: #9ca3af;
    opacity: 1;
    /* importante en algunos navegadores */
}

/* Texto real negro fuerte */
.jm-input {
    width: 100%;
    padding: 6px 8px;
}

.jm-input[readonly] {
    background: #f1f1f1;
    color: #666;
    border-color: #d1d5db;
    cursor: not-allowed;
}

/* Cuando está vacío (solo placeholder visible) */
.jm-input:placeholder-shown {
    color: #9ca3af;
}


/* ===== MODAL SIMPLE ===== */

.jm-modal-hidden {
    display: none;
}

.jm-modal-show {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999999;
}

.jm-modal-box {
    background: #fff;
    width: 380px;
    max-width: 90%;
    border-radius: 14px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, .25);
}

.jm-modal-box h3 {
    margin-top: 0;
    color: #ff3b30;
    font-weight: 800;
}

.jm-modal-box p {
    color: #444;
    margin-bottom: 16px;
}

.jm-modal-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
}


.jm-input,
.jm-select {
    color: #111827 !important;
    font-weight: 600 !important;
}



.jm-modal-box-lg {
    width: 560px;
    max-width: 92%;
    max-height: 90vh;
    overflow-y: auto;
}

.jm-excel-actions {
    /* NUEVO */
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 14px;
}

#excelFileName {
    /* NUEVO */
    margin-top: 10px;
    text-align: center;
}

/* 2026-08-27 · Tabla con encabezado fijo opaco, igual al módulo Productos */
.jm-table-wrap.vase-ux-sticky-shell {
    position: relative;
    overflow: auto !important;
    isolation: isolate;
}
.jm-table-wrap.vase-ux-sticky-shell .jm-table thead {
    position: relative;
    z-index: 30;
}
.jm-table-wrap.vase-ux-sticky-shell .jm-table thead th {
    position: sticky !important;
    top: 0 !important;
    z-index: 31 !important;
    background: #f8fafc !important;
    background-clip: padding-box !important;
    border-bottom: 1px solid #dfe7f1 !important;
    box-shadow: 0 5px 12px rgba(15, 23, 42, .06) !important;
}
.jm-table-wrap.vase-ux-sticky-shell .jm-table tbody {
    position: relative;
    z-index: 1;
}
