.sge-mobile-container {
    padding: 15px;
}

.sge-card {
    background: #fff;
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.sge-card-header {
    display: flex;
    justify-content: space-between;
    font-size: 16px;
    margin-bottom: 10px;
}

.sge-card-body p {
    margin: 5px 0;
    font-size: 14px;
}

.sge-card-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.sge-card-actions button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
}

.sge-btn-accept {
    background: #1e7e34;
    color: #fff;
}

.sge-btn-reject {
    background: #c82333;
    color: #fff;
}

.sge-panel-title {
    text-align: center;
    margin-bottom: 15px;
}

.sge-mensajero-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
}

.sge-tab {
    padding: 10px 18px;
    border-radius: 25px;
    border: none;
    font-weight: 600;
    background: #e9ecef;
    color: #333;
    cursor: pointer;
}

.sge-tab.active {
    background: #1e7e34;
    color: #fff;
}

.sge-ganancia {
    font-size: 16px;
    font-weight: bold;
    color: #1e7e34;
}

.sge-status-tabs {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
}

.sge-status-tab {
    flex: 1;
    padding: 10px;
    border: none;
    background: #4a4a4a;
    font-weight: 600;
    border-radius: 8px;
    margin: 0 4px;
}

.sge-status-tab.active {
    background: #1e7e34;
    color: #fff;
}

.sge-toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: #1f7a3e;
    color: #fff;
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 14px;
    z-index: 9999;
    transition: all .3s ease;
    box-shadow: 0 5px 20px rgba(0,0,0,.2);
}

.sge-toast.show {
    transform: translateX(-50%) translateY(0);
}

.sge-toast-error {
    background: #c0392b;
}

.sge-badge {
    background: #e74c3c;
    color: white;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 12px;
    margin-left: 6px;
}

.sge-card-new {
    animation: fadeInScale .5s ease;
}

@keyframes fadeInScale {
    0% {
        transform: scale(.9);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.sge-btn-entregado:disabled {
    background: #ccc !important;
    color: #666 !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

/* Wrapper upload */
.sge-upload-wrapper {
    margin-top: 15px;
}

/* Botón grande */
.sge-upload-btn {
    display: block;
    background: #2e7d32;
    color: #fff;
    padding: 14px;
    text-align: center;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-size: 15px;
}

/* Ocultar input real */
.sge-upload-btn input {
    display: none;
}

/* Preview grande */
.sge-image-preview {
    margin-top: 15px;
    text-align: center;
}

.sge-preview-img {
    width: 100%;
    max-height: 250px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* ===== TOPBAR ===== */
.sge-topbar {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    font-size: 20px;
}

#sge-open-sidebar {
    font-size: 22px;
    background: #2e7d32;
    border: none;
    cursor: pointer;
}

/* ===== SIDEBAR ===== */
.sge-sidebar {
    position: fixed;
    top: 0;
    left: -260px;
    width: 260px;
    height: 100%;
    background: #fff;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    transition: 0.3s ease;
    z-index: 1000;
    padding: 20px;
}

.sge-sidebar.active {
    left: 0;
}

.sge-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.sge-sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.sge-menu-item {
    padding: 12px;
    border-radius: 10px;
    border: none;
    background: #4a4a4a;
    cursor: pointer;
    text-align: left;
    font-size: 15px;
}

.sge-menu-item.active {
    background: #2e7d32;
    color: #fff;
}

/* ===== OVERLAY ===== */
#sge-sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.3);
    display: none;
    z-index: 900;
}

#sge-sidebar-overlay.active {
    display: block;
}

.sge-btn-primary {
    background: #2e7d32;
    color: #fff;
    border: none;
    padding: 12px;
    border-radius: 10px;
}

.sge-cuadre-summary-card {
    background: #f4f4f4;
    padding: 15px;
    border-radius: 15px;
    margin-bottom: 20px;
}

.sge-cuadre-card {
    background: #fff;
    padding: 15px;
    border-radius: 15px;
    margin-bottom: 15px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.05);
}

.negativo {
    color: red;
    font-weight: bold;
}

.sge-cuadre-filters {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

/* Inputs de fecha - forzar visibilidad */
.sge-cuadre-filters input[type="date"] {
    background: #ffffff;
    color: #1a1a1a !important;
    font-size: 16px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid #dcdcdc;
    width: 100%;
    box-sizing: border-box;
}

/* Color del texto en iOS */
.sge-cuadre-filters input[type="date"]::-webkit-datetime-edit {
    color: #1a1a1a;
}

/* Icono del calendario */
.sge-cuadre-filters input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(0);
    opacity: 0.8;
}

.sge-cuadre-filters label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
    color: #333;
}

/* Contenedor filtros */
.sge-cuadre-filters {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}

/* Fila label + input horizontal */
.sge-date-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Label */
.sge-date-row label {
    font-weight: 600;
    font-size: 14px;
    min-width: 60px;
    color: #2b2b2b;
}

/* Input date */
.sge-date-row input[type="date"] {
    flex: 1;
    min-width: 0; /* 🔥 evita desbordamiento en flex */
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid #ddd;
    background: #fff;
    font-size: 16px;
    color: #1a1a1a;
    box-sizing: border-box;
}

/* Placeholder visual para navegadores que lo soportan */
.sge-date-row input[type="date"]::placeholder {
    color: #999;
}

/* iOS fix */
.sge-date-row input[type="date"]::-webkit-datetime-edit {
    color: #1a1a1a;
}

/* Botón ancho completo */
.sge-btn-primary {
    width: 100%;
}

.sge-cuadre-day {
    margin-bottom: 25px;
}

.sge-cuadre-date {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
}

.sge-cuadre-day-total {
    margin-top: 10px;
    padding: 12px;
    background: #f3f3f3;
    border-radius: 10px;
    font-size: 14px;
}

.negativo {
    color: #d32f2f;
    font-weight: 600;
}

.sge-payment-section {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}

.sge-payment-options label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
}

.sge-upload-large {
    display: block;
    background: #f3f3f3;
    padding: 14px;
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    cursor: pointer;
    margin-top: 10px;
}

.sge-upload-large input {
    display: none;
}

.sge-preview-consignacion {
    width: 100%;
    margin-top: 10px;
    border-radius: 8px;
}

.hidden {
    display: none;
}

.sge-global-loader {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display:flex;
    align-items:center;
    justify-content:center;
    flex-direction:column;
    z-index:9999;
    color:white;
}

.sge-spinner {
    width:50px;
    height:50px;
    border:5px solid rgba(255,255,255,0.3);
    border-top:5px solid #fff;
    border-radius:50%;
    animation: spin 1s linear infinite;
    margin-bottom:15px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.hidden {
    display:none;
}

/* Contenedor evidencias */
.sge-cuadre-evidencias {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
    align-items: center;
}

/* Botones */
.sge-btn-ver-evidencia {
    width: 90%;
    max-width: 260px;
    padding: 10px 14px;
    background: #4CAF50;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sge-btn-ver-evidencia:hover {
    background: #43a047;
    transform: scale(1.02);
}

.sge-btn-ver-evidencia:active {
    transform: scale(0.98);
}


.sge-image-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.sge-image-modal.hidden {
    display: none;
}

.sge-image-modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

#sge-modal-img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 12px;
}

.sge-close-modal {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
}

.sge-search-wrapper {
    margin: 10px 0 15px;
    display: flex;
    justify-content: center;
}

#sge-search-input {
    width: 95%;
    max-width: 400px;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #ddd;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

#sge-search-input:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 0 2px rgba(76,175,80,0.15);
}

/* =========================
   LOGIN MODERNO SGE
========================= */

body {
    margin: 0;
}

.sge-login-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, #f4f6f8, #eef2f5);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.sge-login-card {
    width: 100%;
    max-width: 400px;
    background: #ffffff;
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.08);
    animation: fadeInUp 0.5s ease;
}

.sge-login-header {
    text-align: center;
    margin-bottom: 30px;
}

.sge-login-header img {
    max-width: 160px;
    margin-bottom: 15px;
}

.sge-login-header h2 {
    margin: 0;
    font-size: 22px;
    font-weight: 600;
    color: #222;
}

.sge-login-header p {
    margin-top: 8px;
    font-size: 14px;
    color: #777;
}

.sge-form-group {
    margin-bottom: 18px;
}

.sge-form-group input {
    width: 100%;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid #e0e0e0;
    font-size: 15px;
    background: #fafafa;
    transition: 0.2s ease;
}

.sge-form-group input:focus {
    background: #fff;
    border-color: #4CAF50;
    box-shadow: 0 0 0 3px rgba(76,175,80,0.15);
    outline: none;
}

.sge-btn-primary:hover {
    background: #43a047;
    transform: translateY(-1px);
}

.sge-login-error {
    margin-top: 14px;
    text-align: center;
    color: #e53935;
    font-size: 14px;
}

/* Animación */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

