/* ====================== */
/* ⚙️ Estilo general */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f9f9f9;
    color: #333;
    margin: 0;
    padding: 0;
    text-align: center;
}

/* ====================== */
/* 🧱 Contenedor */
.contenedor {
    max-width: 1400px;
    margin: 30px auto; /* esto ya centra horizontalmente */
    padding: 25px 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(255, 87, 51, 0.2);
    box-sizing: border-box;

    /* ✅ Agrega esta línea */
    width: calc(100% - 40px); /* Deja un margen de 20px en ambos lados siempre */
}



/* Solo en móvil, que vuelva a ser compacto */
@media (max-width: 600px) {
    .contenedor {
        max-width: 95%;
        padding: 20px 15px;
    }
}


/* ====================== */
/* 🖼️ Logo */
.logo-superior {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}
.logo-jaguar {
    height: 80px;
    transition: transform 0.3s ease;
}
.logo-jaguar:hover {
    transform: scale(1.1);
}

/* ====================== */
/* 🔸 Títulos */
h1, h2, h3 {
    margin: 10px 0;
    color: #ff5733;
    font-weight: bold;
    text-align: center;
    text-shadow: 0 0 5px rgba(255, 87, 51, 0.1);
}

h2, h3 {
    position: relative;
    text-transform: uppercase;
    margin-top: 30px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    display: inline-block;
}

h2::after,
h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 50%;
    height: 3px;
    background-color: #ff5733;
    border-radius: 2px;
    transform: translateX(-50%);
    transition: width 0.3s ease-in-out;
}

h2:hover::after,
h3:hover::after {
    width: 80%;
}

/* ====================== */
/* 📝 Párrafos */
p {
    font-size: 16px;
    color: #555;
    line-height: 1.6;
    margin: 15px 0 25px;
    text-align: left;
    max-width: 550px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
    padding-left: 25px;
}

p::before {
    content: "🔸";
    position: absolute;
    left: 0;
    top: 2px;
    font-size: 18px;
    color: #ff5733;
}

/* ====================== */
/* 📋 Formularios */
form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}
label {
    font-weight: bold;
    color: #555;
    max-width: 350px;
    text-align: left;
    width: 100%;
}

/* En escritorio, que estén alineados igual que los inputs */
@media (min-width: 601px) {
    form {
        align-items: center;
    }
    label {
        text-align: center;
    }
}

input, select, button, textarea {
    width: 100%;
    max-width: 350px;
    padding: 12px;
    border-radius: 6px;
    border: 1px solid #ccc;
    background-color: #fff;
    color: black;
    font-size: 16px;
    box-sizing: border-box;
    transition: all 0.2s ease-in-out;
}
input:focus, select:focus, textarea:focus {
    border-color: black;
    outline: none;
    box-shadow: 0 0 5px rgba(255, 87, 51, 0.4);
}

/* ====================== */
/* 👁️ Input con ícono */
.input-con-icono {
    position: relative;
    width: 100%;
    max-width: 350px;
}
.input-con-icono input {
    padding-right: 35px;
}
.input-con-icono span {
    position: absolute;
    right: 10px;
    top: 12px;
    cursor: pointer;
    color: #ff5733;
}

/* ====================== */
/* 🔘 Botones */
button {
    background: #ff5733;
    color: white;
    font-weight: bold;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}
button:hover {
    background: #ff6f4d;
    transform: scale(1.03);
}
button:active {
    background: #e64a2e;
    transform: scale(0.97);
}

/* ====================== */
/* 📊 Tablas */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: #fff;
}
th, td {
    border: 1px solid #ffab94;
    padding: 10px;
    text-align: center;
}
th {
    background-color: #ff5733;
    color: white;
}
td {
    background-color: #fff3f0;
}

/* ====================== */
/* 🔗 Links */
a {
    color: #ff5733;
    text-decoration: none;
    font-weight: bold;
}
a:hover {
    text-decoration: underline;
    color: #e64a2e;
}

/* ====================== */
/* 📦 Especiales */
.btn-alerta {
    background-color: red;
    color: white;
}
.btn-reportes-realizados {
    background-color: green;
    color: white;
}
.btn-menu {
    padding: 12px;
    font-size: 16px;
    border-radius: 8px;
    background-color: #ff5733;
    color: white;
    max-width: 250px;
    min-width: 200px;
    margin: 8px;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 0 5px rgba(255, 87, 51, 0.3);
}
.btn-menu:hover {
    transform: scale(1.04);
    box-shadow: 0 0 10px rgba(255, 87, 51, 0.4);
}
.btn-menu:active {
    transform: scale(0.96);
}

/* ====================== */
/* 🚪 Sesión y regreso */
.cerrar-sesion,
.regresar-menu {
    position: fixed;
    top: 20px;
    padding: 6px 12px;
    border-radius: 6px;
    background-color: #ff5733;
    box-shadow: 0 0 8px rgba(255, 87, 51, 0.5);
    z-index: 999;
}

.cerrar-sesion {
    right: 20px;
}
.regresar-menu {
    left: 20px;
}
.cerrar-sesion a,
.regresar-menu a {
    color: white;
    text-decoration: none;
}
.cerrar-sesion a:hover,
.regresar-menu a:hover {
    color: yellow;
}
.actualizar-datos {
    position: fixed;
    top: 20px;
    padding: 6px 12px;
    border-radius: 6px;
    background-color: blue;
    box-shadow: 0 0 8px rgba(255, 87, 51, 0.5);
    z-index: 999;
}
.actualizar-datos {
    left: 20px;
}
.actualizar-datos a {
    color: white;
    text-decoration: none;
}
.actualizar-datos a:hover {
    color: red;
}
/* ====================== */
/* 📱 Responsive */
@media (max-width: 600px) {
    .contenedor {
        margin: 20px;
        padding: 20px 15px;
    }
    h1 {
        font-size: 22px;
    }
    input, select, button {
        font-size: 16px;
        max-width: 100%;
    }
    .logo-jaguar {
        height: 60px;
    }
}

/* ====================== */
/* 🧷 Cinta horizontal (scroll para tablas en móvil) */
/* Estilo general para escritorio */
/* 📊 Ajuste real de tabla al contenedor */
.tabla-scroll {
    width: 100%;
    overflow-x: auto;
    margin-top: 20px;
}

.tabla-scroll table {
    width: 100%;
    min-width: 750px; /* ✅ permite que tenga scroll si no cabe */
    border-collapse: collapse;
    background-color: white;
}


@media (max-width: 768px) {
    .tabla-scroll {
        overflow-x: auto;
    }

    .tabla-scroll table {
        min-width: 1000px; /* ✅ Solo en pantallas pequeñas se activa el scroll */
    }

    .tabla-scroll::-webkit-scrollbar {
        height: 8px;
    }

    .tabla-scroll::-webkit-scrollbar-thumb {
        background: #ff5733;
        border-radius: 4px;
    }

    .tabla-scroll::-webkit-scrollbar-track {
        background: #ffe5df;
    }
}


.select2-container .select2-selection--single {
    height: 42px !important;
    display: flex !important;
    align-items: center !important;
    padding-left: 10px;
    font-size: 16px;
}

.select2-container .select2-selection__rendered {
    line-height: normal !important;
    padding-left: 0 !important;
    white-space: nowrap;
}

.select2-container .select2-selection__arrow {
    height: 100% !important;
}
/* Estilo único para el botón de asignación */
.btn-asignacion {
    background-color: #ffa31a;
    color: white;
    font-weight: bold;
    border-radius: 10px;
    border: none;
    padding: 12px 20px;
    margin-top: 4px;
    box-shadow: 0 4px 8px rgba(255, 163, 26, 0.3);
    transition: all 0.3s ease-in-out;
}
.btn-asignacion:hover {
    background-color: #e69500;
    transform: scale(1.04);
}

/* Botones naranja para acciones */
.btn-naranja {
    background-color: #ff7f50;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px;
    margin: 4px 0;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
}
.btn-naranja:hover {
    background-color: #e76f41;
    transform: scale(1.03);
}

/* Botón rojo llamativo */
.btn-falla {
    background: linear-gradient(45deg, red, darkred);
    color: white;
    font-weight: bold;
    border: none;
    border-radius: 10px;
    padding: 12px;
    margin: 10px 0;
    animation: pulse 2s infinite;
    box-shadow: 0 0 10px rgba(255, 0, 0, 0.5);
    cursor: pointer;
}
@keyframes pulse {
    0% { box-shadow: 0 0 8px rgba(255, 0, 0, 0.4); }
    50% { box-shadow: 0 0 16px rgba(255, 0, 0, 0.7); }
    100% { box-shadow: 0 0 8px rgba(255, 0, 0, 0.4); }
}

/* Botones informativos azul claro */
.btn-info {
    background-color: #6ec1e4;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px;
    margin: 4px 0;
    font-weight: bold;
    transition: background-color 0.3s ease;
}
btn-info:hover {
    background-color: #5aaed1;
}

/* ====================== */
/* 📦 Organización de botones del operador */
.menu-operador {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 20px;
}

.menu-operador a {
    width: 100%;
    max-width: 400px;
    text-align: center;
    text-decoration: none;
}
/* Modal base */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.6);
  backdrop-filter: blur(2px);
}

/* Contenido del modal */
.modal-contenido {
  background-color: #fff;
  margin: 8% auto;
  padding: 20px 30px;
  border: 2px solid #ff5733;
  width: 90%;
  max-width: 500px;
  border-radius: 10px;
  box-shadow: 0 0 15px rgba(255, 87, 51, 0.4);
  animation: slideDown 0.4s ease-out;
}

/* Cierre (X) */
.cerrar-modal {
  color: #ff5733;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}
.cerrar-modal:hover {
  color: #e64a2e;
}

/* Animación */
@keyframes slideDown {
  from { transform: translateY(-50px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.obras-asignadas {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
}

.obra-chip {
    background-color: #ffe8e2;
    color: #333;
    padding: 6px 10px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(255, 87, 51, 0.15);
    white-space: nowrap;
}
/* ====================== */
/* 🧰 Botones Personalizados */
.btn-accion {
    padding: 10px 18px;
    font-size: 16px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    color: white;
    margin: 5px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    cursor: pointer;
}

.btn-accion:hover {
    transform: scale(1.04);
    box-shadow: 0 6px 10px rgba(0,0,0,0.15);
}

.btn-accion:active {
    transform: scale(0.95);
}

/* Colores temáticos */
.btn-accion.naranja {
    background-color: #ff5733;
}

.btn-accion.verde {
    background-color: #28a745;
}

.btn-accion.azul {
    background-color: #007bff;
}

.btn-accion.gris {
    background-color: #6c757d;
}

.btn-accion.morado {
    background-color: #8e44ad;
}
.btn-accion.ros {
    background-color: #712268;
}
.boton-descarga {
  display: inline-block;
  padding: 10px 20px;
  background-color: #4CAF50;
  color: white;
  text-decoration: none;
  border-radius: 5px;
  margin-top: 20px;
  font-weight: bold;
}
.boton-descarga i {
  margin-right: 8px;
}

.boton-apk-flotante {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #3ddc84;
    color: white;
    font-weight: bold;
    padding: 12px 16px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    transition: all 0.3s ease;
    animation: aparecer 0.4s ease-in-out;
}
.boton-apk-flotante:hover {
    transform: scale(1.05);
    background-color: #34c176;
}

.boton-apk-link {
    color: white;
    text-decoration: none;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Animación suave al aparecer */
@keyframes aparecer {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Ícono de Android opcional si prefieres usar imagen:
.boton-apk-link::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    background-image: url('imagenes/icon-android.png');
    background-size: contain;
    background-repeat: no-repeat;
}
*/
.seccion-tarjeta {
  background: #fff;
  border-radius: 12px;
  padding: 20px 25px;
  margin: 40px auto;
  max-width: 800px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  border-left: 6px solid #ccc;
  position: relative;
}

.seccion-tarjeta h3 {
  margin-top: 0;
  font-weight: bold;
  font-size: 20px;
  margin-bottom: 15px;
  padding-left: 30px;
  position: relative;
}

/* 🔶 Colores por tipo */
.seccion-combustible { border-left-color: #4CAF50; }
.seccion-horometro   { border-left-color: #2196F3; }
.seccion-kilometraje { border-left-color: #FF9800; }

/* 🔧 Íconos a la izquierda del título */
.seccion-combustible h3::before {
  content: "⛽";
  position: absolute;
  left: 0;
  top: 0;
  font-size: 22px;
}

.seccion-horometro h3::before {
  content: "⏱️";
  position: absolute;
  left: 0;
  top: 0;
  font-size: 22px;
}

.seccion-kilometraje h3::before {
  content: "🚗";
  position: absolute;
  left: 0;
  top: 0;
  font-size: 22px;
}
table select {
    width: 100%;
    padding: 6px 10px;
    font-size: 14px;
    border-radius: 6px;
    border: 1px solid #ccc;
}
/* Ajuste para evitar doble línea en Select2 en móvil */
.select2-container--default .select2-selection--single .select2-selection__rendered {
    white-space: normal;
    line-height: 1.2;
}
@media (max-width: 600px) {
  .select2-container {
    width: 100% !important;
    max-width: 100% !important;
    font-size: 16px;
  }

  .select2-container--default .select2-selection--single {
    height: auto !important;
    padding: 12px 10px !important;
    font-size: 16px;
    line-height: 1.4 !important;
  }

  .select2-container--default .select2-selection__rendered {
    white-space: normal !important;
    line-height: 1.3 !important;
    padding-left: 0 !important;
  }

  .select2-dropdown {
    font-size: 16px;
    line-height: 1.4;
  }
}
.btn-accion.rojo {
    background-color: #dc3545; /* Rojo Bootstrap */
}

/* ====================== */
/* 🛑 Mensajes de estado (licencias, errores, alertas) */
.mensaje-alerta {
    text-align: center;
    font-weight: bold;
    margin: 20px auto;
    font-size: 16px;
    max-width: 600px;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* Colores específicos */
.mensaje-verde {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.mensaje-rojo {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.mensaje-naranja {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}
.tipo-registro {
    background-color: #e3f7e3;
    color: #0b6e0b;
    font-weight: bold;
    border-radius: 4px;
    padding: 3px 6px;
    display: inline-block;
}

.tipo-checklist {
    background-color: #e3eaf7;
    color: #0b3e6e;
    font-weight: bold;
    border-radius: 4px;
    padding: 3px 6px;
    display: inline-block;
}
.datos-operador {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px 20px;
    margin: 20px auto;
    max-width: 700px;
    background: #fff7f5;
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 0 8px rgba(255,87,51,0.15);
    font-size: 15px;
    line-height: 1.4;
}
.datos-operador div {
    background-color: #fff;
    border: 1px solid #ffcab9;
    padding: 10px;
    border-radius: 8px;
    font-weight: bold;
    color: #333;
}

