/* Estilos del frontend del plugin Control de Combustible.
   Con prefijo cc- para no chocar con el tema de WordPress. */

.cc-tarjeta {
    background: #ffffff;
    border: 1px solid #e2e2e2;
    border-radius: 12px;
    padding: 28px;
    max-width: 900px;
    margin: 20px auto;
}

.cc-tarjeta-angosta {
    max-width: 480px;
}

.cc-tarjeta h2 { margin-top: 0; }
.cc-subtitulo { color: #6b7280; margin-top: -6px; }

.cc-tarjeta label {
    display: block;
    margin-top: 14px;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.9rem;
}

.cc-tarjeta input[type="text"],
.cc-tarjeta input[type="number"],
.cc-tarjeta input[type="datetime-local"],
.cc-tarjeta input[type="file"],
.cc-tarjeta textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    box-sizing: border-box;
}

.cc-tarjeta textarea { resize: vertical; }

.cc-campo-fijo {
    background: #f3f4f6 !important;
    color: #4b5563 !important;
    cursor: not-allowed;
}

.cc-estado-foto {
    display: block;
    margin-top: 4px;
    font-size: 0.82rem;
    color: #6b7280;
}

.cc-boton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: none;
    border-radius: 10px;
    padding: 12px 18px;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none !important;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.06);
    transition: transform 0.12s ease, box-shadow 0.12s ease, background-color 0.12s ease, border-color 0.12s ease;
}
.cc-boton:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(16, 24, 40, 0.12); }
.cc-boton:active { transform: translateY(0); box-shadow: 0 1px 2px rgba(16, 24, 40, 0.08); }

.cc-boton-primario {
    background: #1d6f42;
    color: #fff;
    margin-top: 20px;
    width: 100%;
}
.cc-boton-primario:hover { background: #14532d; color: #fff; }

.cc-alerta {
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 0.95rem;
}
.cc-alerta-error { background: #fdecea; color: #b91c1c; }
.cc-alerta-exito { background: #eafaf1; color: #14532d; }
.cc-alerta-exito a { color: #14532d; font-weight: 600; text-decoration: underline; margin-left: 6px; }

.cc-alerta-exito-grande {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    background: #eafaf1;
    border: 2px solid #1d6f42;
    border-radius: 12px;
    padding: 22px;
    margin-bottom: 20px;
}
.cc-exito-icono {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #1d6f42;
    color: #fff;
    font-size: 1.6rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cc-exito-titulo {
    margin: 0 0 6px 0;
    font-size: 1.6rem;
    font-weight: bold;
    color: #14532d;
    line-height: 1.2;
}
.cc-exito-detalle {
    margin: 0 0 14px 0;
    font-size: 1.1rem;
    color: #14532d;
}
.cc-alerta-exito-grande .cc-boton { margin-top: 0; }

.cc-encabezado-formulario {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: baseline;
    justify-content: space-between;
}
.cc-encabezado-formulario h2 { margin: 0; }
.cc-enlace-nav {
    font-size: 0.9rem;
    color: #1d6f42;
    text-decoration: none;
    white-space: nowrap;
}
.cc-enlace-nav:hover { text-decoration: underline; }

.cc-acciones-encabezado {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: stretch;
    margin: 14px 0 6px;
}
.cc-acciones-encabezado .cc-boton {
    flex: 1 1 0;
    min-width: 150px;
    text-align: center;
    white-space: normal;
}
.cc-enlace-nav, .cc-enlace-salir {
    text-decoration: none;
}
.cc-boton-secundario {
    background: #eef2f7;
    color: #1f2937;
    border: 1px solid #d7dde5;
}
.cc-boton-secundario:hover { background: #e2e8f0; color: #1f2937; }
.cc-boton-fantasma {
    background: #ffffff;
    color: #6b7280;
    border: 1.5px solid #d1d5db;
    width: auto;
    margin-top: 0;
    padding: 10.5px 16px;
    font-size: 0.9rem;
}
.cc-boton-fantasma:hover { background: #fef2f2; color: #b42318; border-color: #fca5a5; }

.cc-tarjeta-reporte { max-width: 1200px; }

.cc-form-filtros {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: flex-end;
    margin: 16px 0;
    padding: 16px;
    background: #f9fafb;
    border-radius: 8px;
}
.cc-form-filtros > div { min-width: 160px; }
.cc-form-filtros input,
.cc-form-filtros select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-sizing: border-box;
}

.cc-boton-peligro {
    background: #fdecea;
    color: #b91c1c;
    width: auto;
    margin-top: 0;
    padding: 6px 12px;
    font-size: 0.85rem;
    box-shadow: none;
}
.cc-boton-peligro:hover { background: #fbd5d2; color: #b91c1c; }

.cc-barra-lote {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 4px 0 14px;
}
.cc-barra-lote .cc-boton-peligro {
    padding: 10px 18px;
    font-size: 0.9rem;
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.06);
}
.cc-contador-seleccion {
    color: #6b7280;
    font-size: 0.9rem;
}
.cc-tabla input[type="checkbox"],
.wp-list-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.cc-tabla-scroll { overflow-x: auto; }
.cc-tabla { width: 100%; border-collapse: collapse; margin-top: 12px; }
.cc-tabla th, .cc-tabla td {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 1px solid #eee;
    font-size: 0.9rem;
    white-space: nowrap;
}
.cc-tabla th { color: #6b7280; font-weight: 600; }

.cc-miniatura {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid #d1d5db;
}

/* El formulario de login de WordPress dentro de nuestra tarjeta */
.cc-tarjeta .login-username input,
.cc-tarjeta .login-password input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-sizing: border-box;
}
.cc-tarjeta form#loginform p { margin-top: 14px; }
.cc-tarjeta form#loginform .button {
    background: #1d6f42;
    border-color: #14532d;
    color: #fff;
    width: 100%;
    text-align: center;
    padding: 8px;
    border-radius: 8px;
    margin-top: 10px;
}
