/* estilos generales de la app halcon */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    color: #333;
}

/* -- botones -- */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
}

.btn-primary {
    background-color: #c0392b;
    color: white;
}

.btn-primary:hover {
    background-color: #a93226;
}

.btn-secondary {
    background-color: #ecf0f1;
    color: #333;
    border: 1px solid #ccc;
}

.btn-secondary:hover {
    background-color: #dde;
}

.btn-danger {
    background-color: #e74c3c;
    color: white;
}

.btn-success {
    background-color: #27ae60;
    color: white;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 12px;
}

/* inputs y formularios */
input, select, textarea {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    margin-top: 4px;
    font-family: Arial, sans-serif;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #c0392b;
}

label {
    font-size: 13px;
    color: #666;
    display: block;
    margin-top: 12px;
}

.campo {
    margin-bottom: 10px;
}

/* navbar del dashboard */
.navbar {
    background-color: #2c2c2c;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 28px;
}

.navbar h2 {
    color: #e74c3c;
    font-size: 20px;
    letter-spacing: 1px;
}

.navbar .nav-links a {
    color: rgba(255,255,255,0.75);
    text-decoration: none;
    margin-left: 20px;
    font-size: 14px;
}

.navbar .nav-links a:hover {
    color: white;
}

.navbar .nav-links a.activo {
    color: #e74c3c;
    font-weight: bold;
}

.navbar .usuario-info {
    font-size: 13px;
    color: rgba(255,255,255,0.6);
}

/* contenido principal */
.contenido {
    padding: 28px 32px;
    max-width: 1100px;
    margin: 0 auto;
}

.titulo-pagina {
    font-size: 22px;
    margin-bottom: 6px;
    color: #2c2c2c;
}

.subtitulo {
    color: #888;
    font-size: 13px;
    margin-bottom: 22px;
}

/* tarjetas */
.card {
    background: white;
    border-radius: 8px;
    padding: 20px 24px;
    border: 1px solid #e0e0e0;
    margin-bottom: 20px;
}

/* tabla */
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

th {
    text-align: left;
    padding: 10px 12px;
    background-color: #f8f8f8;
    border-bottom: 2px solid #e0e0e0;
    font-size: 13px;
    color: #555;
}

td {
    padding: 11px 12px;
    border-bottom: 1px solid #f0f0f0;
    vertical-align: middle;
}

tr:hover td {
    background-color: #fafafa;
}

/* badges de estado */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
}

.badge-pedido      { background: #ede9fe; color: #5b21b6; }
.badge-proceso     { background: #fef3c7; color: #92400e; }
.badge-ruta        { background: #dbeafe; color: #1e40af; }
.badge-entregado   { background: #d1fae5; color: #065f46; }
.badge-eliminado   { background: #fee2e2; color: #991b1b; }

/* barra de busqueda */
.barra-busqueda {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.barra-busqueda input,
.barra-busqueda select {
    width: auto;
    flex: 1;
    min-width: 130px;
    margin-top: 0;
}

/* mensajes de alerta */
.alerta {
    padding: 10px 16px;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 14px;
}
.alerta-ok    { background: #d1fae5; color: #065f46; }
.alerta-error { background: #fee2e2; color: #991b1b; }
.alerta-info  { background: #dbeafe; color: #1e40af; }

/* modal */
.modal-fondo {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
    align-items: center;
    justify-content: center;
}

.modal-fondo.visible {
    display: flex;
}

.modal-caja {
    background: white;
    border-radius: 10px;
    padding: 28px;
    width: 100%;
    max-width: 580px;
    max-height: 88vh;
    overflow-y: auto;
}

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

.modal-header h3 {
    font-size: 18px;
}

.cerrar-modal {
    background: #f0f0f0;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    font-size: 16px;
}

/* imagen de evidencia */
.img-evidencia {
    width: 100%;
    max-height: 220px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #ddd;
    margin-top: 8px;
}

/* sin resultados */
.sin-resultados {
    text-align: center;
    padding: 40px;
    color: #aaa;
    font-size: 14px;
}

/* dos columnas rapidas */
.dos-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.acciones {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
